electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 521376f87fad2c931b46537bad49c3457e8aeb44
parent fe1b2149cbadce8e9d4ad5e008e3ee60a0b3c1e4
Author: ThomasV <thomasv@electrum.org>
Date:   Thu, 28 Jan 2021 13:10:43 +0100

rm unused parameter in maybe_fulfill_htlc

Diffstat:
Melectrum/lnpeer.py | 10++++++----
1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/electrum/lnpeer.py b/electrum/lnpeer.py @@ -1369,9 +1369,12 @@ class Peer(Logger): return None, None, OnionRoutingFailureMessage(code=OnionFailureCode.TEMPORARY_CHANNEL_FAILURE, data=data) return next_chan_scid, next_htlc.htlc_id, None - def maybe_fulfill_htlc(self, *, chan: Channel, htlc: UpdateAddHtlc, - onion_packet: OnionPacket, processed_onion: ProcessedOnionPacket, - ) -> Tuple[Optional[bytes], Optional[OnionRoutingFailureMessage]]: + def maybe_fulfill_htlc( + self, *, + chan: Channel, + htlc: UpdateAddHtlc, + processed_onion: ProcessedOnionPacket) -> Tuple[Optional[bytes], Optional[OnionRoutingFailureMessage]]: + info = self.lnworker.get_payment_info(htlc.payment_hash) if info is None: reason = OnionRoutingFailureMessage(code=OnionFailureCode.INCORRECT_OR_UNKNOWN_PAYMENT_DETAILS, data=b'') @@ -1697,7 +1700,6 @@ class Peer(Logger): preimage, error_reason = self.maybe_fulfill_htlc( chan=chan, htlc=htlc, - onion_packet=onion_packet, processed_onion=processed_onion) elif not forwarding_info: next_chan_id, next_htlc_id, error_reason = self.maybe_forward_htlc(