From 39c331a7b92de288b5505bec58af2d25270077a5 Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Mon, 5 Oct 2020 08:46:20 -0300 Subject: [PATCH] fix opennode stupid syntax errors. --- lnbits/wallets/opennode.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lnbits/wallets/opennode.py b/lnbits/wallets/opennode.py index e910a31..497afd2 100644 --- a/lnbits/wallets/opennode.py +++ b/lnbits/wallets/opennode.py @@ -42,7 +42,7 @@ class OpenNodeWallet(Wallet): data = r.json()["data"] checking_id = data["id"] payment_request = data["lightning_invoice"]["payreq"] - return InvoiceResponse(True, checking_id, payment_request, error_message) + return InvoiceResponse(True, checking_id, payment_request, None) def pay_invoice(self, bolt11: str) -> PaymentResponse: r = httpx.post( @@ -54,9 +54,9 @@ class OpenNodeWallet(Wallet): return PaymentResponse(False, None, 0, error_message) data = r.json()["data"] - checking_id, fee_msat = data["id"] + checking_id = data["id"] fee_msat = data["fee"] * 1000 - return PaymentResponse(True, checking_id, fee_msat, error_message) + return PaymentResponse(True, checking_id, fee_msat, None) def get_invoice_status(self, checking_id: str) -> PaymentStatus: r = httpx.get(f"{self.endpoint}/v1/charge/{checking_id}", headers=self.auth_invoice)