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:
6 files changed
+43
-37
No files matched your search
@@ -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