mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-08-29 15:11:09 +02:00
channelnotifier+discover+invoices: return error in Stop functions
In order to be consistent with other sub systems an error is now returned from the Stop functions. This also allows writing a generic cleanup mechanism to stop all sub systems in case of a failure.
This commit is contained in:
@@ -461,8 +461,9 @@ func (d *AuthenticatedGossiper) start() error {
|
||||
}
|
||||
|
||||
// Stop signals any active goroutines for a graceful closure.
|
||||
func (d *AuthenticatedGossiper) Stop() {
|
||||
func (d *AuthenticatedGossiper) Stop() error {
|
||||
d.stopped.Do(d.stop)
|
||||
return nil
|
||||
}
|
||||
|
||||
func (d *AuthenticatedGossiper) stop() {
|
||||
|
Reference in New Issue
Block a user