mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-07-28 13:52:55 +02:00
htlcswitch: introduce and embed packetHandler interface in ChannelLink
This will allow separating the now-private *htlcPacket methods from the publicly-used ChannelLink interface methods.
This commit is contained in:
@@ -509,7 +509,7 @@ func (s *Switch) SendHTLC(firstHop lnwire.ShortChannelID, attemptID uint64,
|
||||
return linkErr
|
||||
}
|
||||
|
||||
return link.HandleLocalAddPacket(packet)
|
||||
return link.handleLocalAddPacket(packet)
|
||||
}
|
||||
|
||||
// UpdateForwardingPolicies sends a message to the switch to update the
|
||||
@@ -1101,7 +1101,7 @@ func (s *Switch) handlePacketForward(packet *htlcPacket) error {
|
||||
// Send the packet to the destination channel link which
|
||||
// manages the channel.
|
||||
packet.outgoingChanID = destination.ShortChanID()
|
||||
return destination.HandleSwitchPacket(packet)
|
||||
return destination.handleSwitchPacket(packet)
|
||||
|
||||
case *lnwire.UpdateFailHTLC, *lnwire.UpdateFulfillHTLC:
|
||||
// If the source of this packet has not been set, use the
|
||||
|
Reference in New Issue
Block a user