fix: show proper total balances fix cleanups (#2490)
payments are not deleted oif we delete a wallets, so to get a accurate total representation of the lnbits balance we need to create the balances view based on the wallets table, not payments, else deleted balances will still show up. 2nd, delete_unused_wallets and delete_accounts was never working if because they never got an updated_at time, so i just check if its null else i check to timedelta on created_at
This commit is contained in:
+1
-1
@@ -206,7 +206,7 @@ async def database_delete_wallet(wallet: str):
|
||||
@click.option("-c", "--checking-id", required=True, help="Payment checking Id.")
|
||||
@coro
|
||||
async def database_delete_wallet_payment(wallet: str, checking_id: str):
|
||||
"""Mark wallet as deleted"""
|
||||
"""Delete wallet payment"""
|
||||
async with core_db.connect() as conn:
|
||||
await delete_wallet_payment(
|
||||
wallet_id=wallet, checking_id=checking_id, conn=conn
|
||||
|
||||
Reference in New Issue
Block a user