lnworker: minor fix, follow-up fc4f995668
This commit is contained in:
@@ -2643,7 +2643,7 @@ class LNWallet(LNWorker):
|
|||||||
self.logger.info(f"received unknown htlc_failed, probably from previous session (phash={payment_hash.hex()})")
|
self.logger.info(f"received unknown htlc_failed, probably from previous session (phash={payment_hash.hex()})")
|
||||||
key = payment_hash.hex()
|
key = payment_hash.hex()
|
||||||
invoice = self.wallet.get_invoice(key)
|
invoice = self.wallet.get_invoice(key)
|
||||||
if self.get_invoice_status(invoice) != PR_UNPAID:
|
if invoice and self.get_invoice_status(invoice) != PR_UNPAID:
|
||||||
self.set_invoice_status(key, PR_UNPAID)
|
self.set_invoice_status(key, PR_UNPAID)
|
||||||
util.trigger_callback('payment_failed', self.wallet, key, '')
|
util.trigger_callback('payment_failed', self.wallet, key, '')
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user