From abbcfbeb6a5de07fcbabdc29fc32fe35cd45adca Mon Sep 17 00:00:00 2001 From: Kalle Rosenbaum Date: Tue, 19 Dec 2023 12:12:52 +0100 Subject: [PATCH] cln: allow unpaid amountless invoices (#2138) --- lnbits/nodes/cln.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lnbits/nodes/cln.py b/lnbits/nodes/cln.py index 880e21eea..1fdca0f42 100644 --- a/lnbits/nodes/cln.py +++ b/lnbits/nodes/cln.py @@ -312,8 +312,12 @@ class CoreLightningNode(Node): NodeInvoice( bolt11=invoice.get("bolt11") or invoice.get("bolt12"), amount=( + # normal invoice invoice.get("amount_msat") + # keysend or paid amountless invoice or invoice.get("amount_received_msat") + # unpaid amountless invoice + or 0 ), preimage=invoice.get("payment_preimage"), memo=invoice.get("description"),