From 0cf11caaadf282ea499ed0cdc8cd8bf1ff29ca4b Mon Sep 17 00:00:00 2001 From: benarc Date: Mon, 18 Oct 2021 10:31:30 +0100 Subject: [PATCH] copilot payments not triggering animations listener issue --- lnbits/extensions/copilot/lnurl.py | 1 - lnbits/extensions/copilot/tasks.py | 9 ++------- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/lnbits/extensions/copilot/lnurl.py b/lnbits/extensions/copilot/lnurl.py index cafb5921..367b1343 100644 --- a/lnbits/extensions/copilot/lnurl.py +++ b/lnbits/extensions/copilot/lnurl.py @@ -57,7 +57,6 @@ async def lnurl_callback( raise HTTPException( status_code=HTTPStatus.NOT_FOUND, detail="Copilot not found" ) - print(cp) amount_received = int(amount) if amount_received < 10000: diff --git a/lnbits/extensions/copilot/tasks.py b/lnbits/extensions/copilot/tasks.py index bac260aa..417f885f 100644 --- a/lnbits/extensions/copilot/tasks.py +++ b/lnbits/extensions/copilot/tasks.py @@ -26,15 +26,10 @@ async def wait_for_paid_invoices(): async def on_invoice_paid(payment: Payment) -> None: webhook = None data = None - print("cunt") if "copilot" != payment.extra.get("tag"): # not an copilot invoice return - if payment.extra.get("wh_status"): - # this webhook has already been sent - return - copilot = await get_copilot(payment.extra.get("copilot", -1)) if not copilot: @@ -71,8 +66,8 @@ async def on_invoice_paid(payment: Payment) -> None: await mark_webhook_sent(payment, -1) if payment.extra.get("comment"): await updater(copilot.id, data, payment.extra.get("comment")) - else: - await updater(copilot.id, data, "none") + + await updater(copilot.id, data, "none") async def mark_webhook_sent(payment: Payment, status: int) -> None: