Skip to content

Commit

Permalink
rc5
Browse files Browse the repository at this point in the history
  • Loading branch information
dni committed Oct 18, 2024
1 parent bf22f52 commit 889a5fa
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 30 deletions.
50 changes: 25 additions & 25 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion views.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from http import HTTPStatus

from fastapi import APIRouter, Depends, Request, HTTPException
from fastapi import APIRouter, Depends, HTTPException, Request
from fastapi.responses import HTMLResponse

from lnbits.core.models import User
Expand Down
8 changes: 4 additions & 4 deletions views_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from fastapi import APIRouter, Depends, HTTPException, Query

from lnbits.core.crud import get_user_by_id
from lnbits.core.crud import get_user
from lnbits.core.models import WalletTypeInfo
from lnbits.decorators import require_admin_key, require_invoice_key

Expand All @@ -29,7 +29,7 @@ async def api_cards(
wallet_ids = [key_info.wallet.id]

if all_wallets:
user = await get_user_by_id(key_info.wallet.user)
user = await get_user(key_info.wallet.user)
wallet_ids = user.wallet_ids if user else []

return await get_cards(wallet_ids)
Expand Down Expand Up @@ -153,7 +153,7 @@ async def api_hits(
wallet_ids = [key_info.wallet.id]

if all_wallets:
user = await get_user_by_id(key_info.wallet.user)
user = await get_user(key_info.wallet.user)
wallet_ids = user.wallet_ids if user else []

cards = await get_cards(wallet_ids)
Expand All @@ -172,7 +172,7 @@ async def api_refunds(
wallet_ids = [key_info.wallet.id]

if all_wallets:
user = await get_user_by_id(key_info.wallet.user)
user = await get_user(key_info.wallet.user)
wallet_ids = user.wallet_ids if user else []

cards = await get_cards(wallet_ids)
Expand Down

0 comments on commit 889a5fa

Please sign in to comment.