mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-03-04 17:55:36 +01:00
Merge branch '0-18-5-branch-rc2-9383' into 0-18-5-branch-rc2
This commit is contained in:
commit
8f5e3f08ca
1 changed files with 10 additions and 2 deletions
|
@ -317,8 +317,16 @@ func (r *Manager) createEdge(channel *channeldb.OpenChannel,
|
|||
err)
|
||||
}
|
||||
|
||||
// We need to make sure we use the real scid for public confirmed
|
||||
// zero-conf channels.
|
||||
shortChanID := channel.ShortChanID()
|
||||
isPublic := channel.ChannelFlags&lnwire.FFAnnounceChannel != 0
|
||||
if isPublic && channel.IsZeroConf() && channel.ZeroConfConfirmed() {
|
||||
shortChanID = channel.ZeroConfRealScid()
|
||||
}
|
||||
|
||||
info := &models.ChannelEdgeInfo{
|
||||
ChannelID: channel.ShortChanID().ToUint64(),
|
||||
ChannelID: shortChanID.ToUint64(),
|
||||
ChainHash: channel.ChainHash,
|
||||
Features: featureBuf.Bytes(),
|
||||
Capacity: channel.Capacity,
|
||||
|
@ -334,7 +342,7 @@ func (r *Manager) createEdge(channel *channeldb.OpenChannel,
|
|||
// be updated with the new values in the call to processChan below.
|
||||
timeLockDelta := uint16(r.DefaultRoutingPolicy.TimeLockDelta)
|
||||
edge := &models.ChannelEdgePolicy{
|
||||
ChannelID: channel.ShortChanID().ToUint64(),
|
||||
ChannelID: shortChanID.ToUint64(),
|
||||
LastUpdate: timestamp,
|
||||
TimeLockDelta: timeLockDelta,
|
||||
ChannelFlags: channelFlags,
|
||||
|
|
Loading…
Add table
Reference in a new issue