Skip to content

Commit

Permalink
Enable bolt11 mint method for EUR
Browse files Browse the repository at this point in the history
  • Loading branch information
minibits-cash committed May 10, 2024
1 parent fc6652d commit 9d1b4af
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions cashu/core/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ class MintBackends(MintSettings):
mint_lightning_backend: str = Field(default="") # deprecated
mint_backend_bolt11_sat: str = Field(default="")
mint_backend_bolt11_usd: str = Field(default="")
mint_backend_bolt11_eur: str = Field(default="")

mint_lnbits_endpoint: str = Field(default=None)
mint_lnbits_key: str = Field(default=None)
Expand Down
5 changes: 5 additions & 0 deletions cashu/mint/startup.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@
unit=Unit.usd
)
backends.setdefault(Method.bolt11, {})[Unit.usd] = backend_bolt11_usd
if settings.mint_backend_bolt11_eur:
backend_bolt11_eur = getattr(wallets_module, settings.mint_backend_bolt11_eur)(
unit=Unit.eur
)
backends.setdefault(Method.bolt11, {})[Unit.eur] = backend_bolt11_eur
if not backends:
raise Exception("No backends are set.")

Expand Down

0 comments on commit 9d1b4af

Please sign in to comment.