multi: add bool param to channel enable/disable methods

Add a new boolean parameter without changing any existing
functionality. The parameter will be used to indicate
whether a request to update a channel's status was made
manually by a user (currently always false).
This commit is contained in:
Elliott Jin committed 2021-02-24 07:13:28 -08:00
1 parent db23e34f74
commit e9baf0e4a2
4 files changed
+31 -15

No files matched your search

+3 -1
View File
@@ -965,7 +965,9 @@ func newServer(cfg *Config, listenAddrs []net.Addr,
return ErrServerShuttingDown
}
},
DisableChannel: s.chanStatusMgr.RequestDisable,
DisableChannel: func(chanPoint wire.OutPoint) error {
return s.chanStatusMgr.RequestDisable(chanPoint, false)
},
Sweeper: s.sweeper,
Registry: s.invoices,
NotifyClosedChannel: s.channelNotifier.NotifyClosedChannelEvent,