Skip to content

Commit

Permalink
update env.example, remove mean comment about the hmac auth token
Browse files Browse the repository at this point in the history
  • Loading branch information
lollerfirst committed Aug 13, 2024
1 parent 8140b19 commit 1aefc69
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
7 changes: 7 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,13 @@ MINT_BLINK_KEY=blink_abcdefgh
# Use with StrikeWallet for BTC, USD, and EUR
MINT_STRIKE_KEY=ABC123

# Use with LNMarketsWallet for USD
# you can also specify paths from which `ACCESS_KEY`, `SECRET` and `PASSPHRASE` will be read
MINT_LNMARKETS_REST_URL="https://api.lnmarkets.com"
MINT_LNMARKETS_REST_ACCESS_KEY="<YOUR_API_ACCESS_KEY>"
MINT_LNMARKETS_REST_SECRET="<YOUR_API_SECRET>"
MINT_LNMARKETS_REST_PASSPHRASE="<YOUR_API_PASSPHRASE>"

# fee to reserve in percent of the amount
LIGHTNING_FEE_PERCENT=1.0
# minimum fee to reserve
Expand Down
3 changes: 1 addition & 2 deletions cashu/lightning/lnmarkets.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,7 @@ async def create_invoice(
data = None
path = None
if self.unit == Unit.usd:
# The ""signature"" of LNMarkets is the sketchiest thing I have ever seen.
# I don't know who came up with that. Anyway, we do this trick to avoid messing it up.
# We do this trick to avoid messing it up.
amount_usd = float(amount.to_float_string())
amount_usd = int(amount_usd) if float(int(amount_usd)) == amount_usd else amount_usd
data = {"amount": amount_usd, "currency": "usd"}
Expand Down

0 comments on commit 1aefc69

Please sign in to comment.