mirror of
https://github.com/lnbits/lnbits-legend.git
synced 2025-03-12 02:08:38 +01:00
Merge pull request #477 from talvasconcelos/fix/watchonly
get only one address instead of multiple
This commit is contained in:
commit
6645b156e7
1 changed files with 2 additions and 4 deletions
|
@ -82,11 +82,9 @@ async def api_wallet_delete(wallet_id, w: WalletTypeInfo = Depends(require_admin
|
||||||
|
|
||||||
@watchonly_ext.get("/api/v1/address/{wallet_id}")
|
@watchonly_ext.get("/api/v1/address/{wallet_id}")
|
||||||
async def api_fresh_address(wallet_id, w: WalletTypeInfo = Depends(get_key_type)):
|
async def api_fresh_address(wallet_id, w: WalletTypeInfo = Depends(get_key_type)):
|
||||||
await get_fresh_address(wallet_id)
|
address = await get_fresh_address(wallet_id)
|
||||||
|
|
||||||
addresses = await get_addresses(wallet_id)
|
return [address.dict()]
|
||||||
|
|
||||||
return [address.dict() for address in addresses]
|
|
||||||
|
|
||||||
|
|
||||||
@watchonly_ext.get("/api/v1/addresses/{wallet_id}")
|
@watchonly_ext.get("/api/v1/addresses/{wallet_id}")
|
||||||
|
|
Loading…
Add table
Reference in a new issue