fixup
This commit is contained in:
parent
66c0aac3a1
commit
840de18a91
|
@ -118,6 +118,7 @@ async def create_lnurldevicepayment(
|
||||||
sats: Optional[int] = 0,
|
sats: Optional[int] = 0,
|
||||||
) -> lnurldevicepayment:
|
) -> lnurldevicepayment:
|
||||||
device = await get_lnurldevice(deviceid)
|
device = await get_lnurldevice(deviceid)
|
||||||
|
assert device
|
||||||
if device.device == "atm":
|
if device.device == "atm":
|
||||||
lnurldevicepayment_id = shortuuid.uuid(name=payload)
|
lnurldevicepayment_id = shortuuid.uuid(name=payload)
|
||||||
else:
|
else:
|
||||||
|
|
|
@ -236,13 +236,10 @@ async def lnurl_callback(
|
||||||
else:
|
else:
|
||||||
if lnurldevicepayment.payload != k1:
|
if lnurldevicepayment.payload != k1:
|
||||||
return {"status": "ERROR", "reason": "Bad K1"}
|
return {"status": "ERROR", "reason": "Bad K1"}
|
||||||
<<<<<<< HEAD
|
|
||||||
lnurldevicepayment = await update_lnurldevicepayment(
|
|
||||||
=======
|
|
||||||
if lnurldevicepayment.payhash != "payment_hash":
|
if lnurldevicepayment.payhash != "payment_hash":
|
||||||
return {"status": "ERROR", "reason": f"Payment already claimed"}
|
return {"status": "ERROR", "reason": f"Payment already claimed"}
|
||||||
|
|
||||||
lnurldevicepayment_updated = await update_lnurldevicepayment(
|
lnurldevicepayment_updated = await update_lnurldevicepayment(
|
||||||
>>>>>>> c2f4a7c9 (fix mypy lnurldevices issues)
|
|
||||||
lnurldevicepayment_id=paymentid, payhash=lnurldevicepayment.payload
|
lnurldevicepayment_id=paymentid, payhash=lnurldevicepayment.payload
|
||||||
)
|
)
|
||||||
assert lnurldevicepayment_updated
|
assert lnurldevicepayment_updated
|
||||||
|
|
Loading…
Reference in New Issue
Block a user