From a41368516057577e4b392cd6d6f06816ca2ffaf6 Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Sat, 17 Apr 2021 23:30:26 -0300 Subject: [PATCH] fix redeem_lnurl_withdraw code. --- lnbits/core/services.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lnbits/core/services.py b/lnbits/core/services.py index 39b2eaed..8ccf1a42 100644 --- a/lnbits/core/services.py +++ b/lnbits/core/services.py @@ -193,7 +193,7 @@ async def redeem_lnurl_withdraw( _, payment_request = await create_invoice( wallet_id=wallet_id, - amount=res["maxWithdrawable"], + amount=int(res["maxWithdrawable"] / 1000), memo=memo or res["defaultDescription"] or "", extra=extra, conn=conn, @@ -208,7 +208,7 @@ async def redeem_lnurl_withdraw( "balanceNotify": url_for( "core.lnurl_balance_notify", service=urlparse(lnurl_request).netloc, - wal=g.wallet.id, + wal=wallet_id, _external=True, ), },