update text

This commit is contained in:
callebtc
2022-12-27 19:30:53 +01:00
parent e230b873fe
commit 639fab547e
2 changed files with 8 additions and 5 deletions

View File

@@ -334,7 +334,10 @@ async def receive(ctx, token: str, lock: str):
# if it was not an lnbits link # if it was not an lnbits link
if url is None: if url is None:
url = input(f"Enter mint URL (default: {MINT_URL}: ") or MINT_URL url = (
input(f"Enter mint URL (or press enter for default: {MINT_URL}: ")
or MINT_URL
)
# and add url and keyset id to token from link extraction above # and add url and keyset id to token from link extraction above
if url: if url:

View File

@@ -87,7 +87,7 @@ async def print_mint_balances(ctx, wallet, show_mints=False):
print("") print("")
for i, (k, v) in enumerate(mint_balances.items()): for i, (k, v) in enumerate(mint_balances.items()):
print( print(
f"Mint {i+1}: {k} - Balance: {v['available']} sat (pending: {v['balance']-v['available']} sat)" f"Mint {i+1}: Balance: {v['available']} sat (pending: {v['balance']-v['available']} sat) URL: {k}"
) )
print("") print("")
@@ -103,10 +103,10 @@ async def get_mint_wallet(ctx):
await print_mint_balances(ctx, wallet, show_mints=True) await print_mint_balances(ctx, wallet, show_mints=True)
mint_nr = input( mint_nr = (
f"Which mint do you want to use? [1-{len(mint_balances)}, default: 1] " input(f"Select mint [1-{len(mint_balances)}, press enter for default 1]: ")
or "1"
) )
mint_nr = "1" if mint_nr == "" else mint_nr
if not mint_nr.isdigit(): if not mint_nr.isdigit():
raise Exception("invalid input.") raise Exception("invalid input.")
mint_nr = int(mint_nr) mint_nr = int(mint_nr)