return http error UNAUTHORIZED instead of BAD_REQUEST if key is missing (#869)
* return http error UNAUTHORIZED instead of BAD_REQUEST if key is missing * fix regtest (#867) Co-authored-by: dni <dni.khr@gmail.com> * return http error UNAUTHORIZED instead of BAD_REQUEST if key is missing Co-authored-by: dni ⚡ <office@dnilabs.com> Co-authored-by: dni <dni.khr@gmail.com>
This commit is contained in:
@@ -270,7 +270,7 @@ async def api_payments_create(
|
||||
return await api_payments_create_invoice(invoiceData, wallet.wallet)
|
||||
else:
|
||||
raise HTTPException(
|
||||
status_code=HTTPStatus.BAD_REQUEST,
|
||||
status_code=HTTPStatus.UNAUTHORIZED,
|
||||
detail="Invoice (or Admin) key required.",
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user