From 5a74f52712c087840c2e969290c31c25f98147d7 Mon Sep 17 00:00:00 2001 From: Arc <33088785+arcbtc@users.noreply.github.com> Date: Tue, 4 Feb 2020 22:53:00 +0000 Subject: [PATCH] Update views_api.py --- lnbits/extensions/withdraw/views_api.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lnbits/extensions/withdraw/views_api.py b/lnbits/extensions/withdraw/views_api.py index bc7476c..4520724 100644 --- a/lnbits/extensions/withdraw/views_api.py +++ b/lnbits/extensions/withdraw/views_api.py @@ -13,7 +13,7 @@ from lnbits.extensions.withdraw import withdraw_ext @withdraw_ext.route("/api/v1/lnurlencode//", methods=["GET"]) def api_lnurlencode(urlstr, parstr): """Returns encoded LNURL if web url and parameter gieven.""" - print(urlstr) + if not urlstr: return jsonify({"status": "FALSE"}), 200 @@ -27,7 +27,7 @@ def api_lnurlencode(urlstr, parstr): rand = randar[user_fau[0][10] - 1] else: rand = randar[0] - print(rand) + url = url_for("withdraw.api_lnurlfetch", _external=True, urlstr=urlstr, parstr=parstr, rand=rand) @@ -57,7 +57,7 @@ def api_lnurlfetch(parstr, urlstr, rand): max_withdrawable=user_fau[0][7] * 1000, default_description="LNbits LNURL withdraw", ) - print(res.json()) + return res.json(), 200