channeldb: in RestoreChannelShells don't exit if edge already exists
During the restore process, it may be possible that we have already heard about our prior edge from a node on the network (or our channel peers). As a result, we shouldn't exit if this happens, and instead should continue with the rest of the restoration process.
This commit is contained in:
parent
26c52892cb
commit
b8cbe3a1f8
@ -965,7 +965,7 @@ func (d *DB) RestoreChannelShells(channelShells ...*ChannelShell) error {
|
|||||||
// With the edge info shell constructed, we'll now add
|
// With the edge info shell constructed, we'll now add
|
||||||
// it to the graph.
|
// it to the graph.
|
||||||
err = chanGraph.addChannelEdge(tx, &edgeInfo)
|
err = chanGraph.addChannelEdge(tx, &edgeInfo)
|
||||||
if err != nil {
|
if err != nil && err != ErrEdgeAlreadyExist {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user