Skip to content

Commit

Permalink
weird error
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Oct 2, 2024
1 parent 7685889 commit 6c60e14
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions cashu/lightning/lnbits.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,8 @@ async def create_invoice(
url=f"{self.endpoint}/api/v1/payments", json=data
)
r.raise_for_status()
except Exception:
return InvoiceResponse(
ok=False,
error_message=r.json()["detail"],
)
except Exception as e:
return InvoiceResponse(ok=False, error_message=str(e))

data = r.json()
checking_id, payment_request = data["checking_id"], data["payment_request"]
Expand Down

0 comments on commit 6c60e14

Please sign in to comment.