mirror of
https://github.com/lnbits/lnbits.git
synced 2025-04-07 19:38:13 +02:00
Stopped 0 invoice creation in tickets
This commit is contained in:
parent
435b4056fd
commit
ffba97850b
@ -103,6 +103,10 @@ async def api_ticket_make_ticket(data: CreateTicketData, form_id):
|
||||
raise HTTPException(
|
||||
status_code=HTTPStatus.NOT_FOUND, detail=f"LNTicket does not exist."
|
||||
)
|
||||
if data.sats < 1:
|
||||
raise HTTPException(
|
||||
status_code=HTTPStatus.NOT_FOUND, detail=f"0 invoices not allowed."
|
||||
)
|
||||
|
||||
nwords = len(re.split(r"\s+", data.ltext))
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user