channeldb+lnwallet: don't pass isRestoredChan to ChanSyncMsg
Since we have access to the internal state of the channel, we can instead get it directly instead of passing it in as a parameter.
This commit is contained in:
6 files changed
+32
-45
No files matched your search
+1
-3
@@ -609,9 +609,7 @@ func (l *channelLink) syncChanStates() error {
|
||||
// side. Based on this message, the remote party will decide if they
|
||||
// need to retransmit any data or not.
|
||||
chanState := l.channel.State()
|
||||
localChanSyncMsg, err := chanState.ChanSyncMsg(
|
||||
chanState.HasChanStatus(channeldb.ChanStatusRestored),
|
||||
)
|
||||
localChanSyncMsg, err := chanState.ChanSyncMsg()
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to generate chan sync message for "+
|
||||
"ChannelPoint(%v)", l.channel.ChannelPoint())
|
||||
|
||||
Reference in new issue
Block a user