diff --git a/channeldb/db.go b/channeldb/db.go index 313ac1f09..763a74c85 100644 --- a/channeldb/db.go +++ b/channeldb/db.go @@ -906,6 +906,12 @@ func (d *DB) RestoreChannelShells(channelShells ...*ChannelShell) error { for _, channelShell := range channelShells { channel := channelShell.Chan + // When we make a channel, we mark that the channel has + // been restored, this will signal to other sub-systems + // to not attempt to use the channel as if it was a + // regular one. + channel.chanStatus |= ChanStatusRestored + // First, we'll attempt to create a new open channel // and link node for this channel. If the channel // already exists, then in order to ensure this method diff --git a/chanrestore.go b/chanrestore.go index adf76397c..3e219489c 100644 --- a/chanrestore.go +++ b/chanrestore.go @@ -101,16 +101,6 @@ func (c *chanDBRestorer) openChannelShell(backup chanbackup.Single) ( }, } - // TODO(roasbeef): move this mapping elsewhere? - - // When we make a channel, we mark that the channel has been restored, - // this will signal to other sub-systems to not attempt to use the - // channel as if it was a regular one. - chanStatus := channeldb.ChanStatusDefault | - channeldb.ChanStatusRestored - - chanShell.Chan.ApplyChanStatus(chanStatus) - return &chanShell, nil }