lnurlp: fix success_url checking.
This commit is contained in:
parent
d9b37c077d
commit
05139b3305
1 changed files with 6 additions and 3 deletions
|
|
@ -88,8 +88,11 @@ async def api_link_create_or_update(link_id=None):
|
||||||
):
|
):
|
||||||
return jsonify({"message": "Must use full satoshis."}), HTTPStatus.BAD_REQUEST
|
return jsonify({"message": "Must use full satoshis."}), HTTPStatus.BAD_REQUEST
|
||||||
|
|
||||||
if g.data["success_url"][:8] != "https://":
|
if "success_url" in g.data and g.data["success_url"][:8] != "https://":
|
||||||
return jsonify({"message": "Success URL must be secure https://..."}), HTTPStatus.BAD_REQUEST
|
return (
|
||||||
|
jsonify({"message": "Success URL must be secure https://..."}),
|
||||||
|
HTTPStatus.BAD_REQUEST,
|
||||||
|
)
|
||||||
|
|
||||||
if link_id:
|
if link_id:
|
||||||
link = await get_pay_link(link_id)
|
link = await get_pay_link(link_id)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue