Stopped 0 invoice creation in tickets
This commit is contained in:
parent
435b4056fd
commit
ffba97850b
1 changed files with 4 additions and 0 deletions
|
|
@ -103,6 +103,10 @@ async def api_ticket_make_ticket(data: CreateTicketData, form_id):
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=HTTPStatus.NOT_FOUND, detail=f"LNTicket does not exist."
|
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))
|
nwords = len(re.split(r"\s+", data.ltext))
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue