Compare commits

..
Author SHA1 Message Date
Shroominic 0bcf7bb948 rm accidental push of cdk-python binaries 2025-11-17 12:26:00 -08:00
3 changed files with 5 additions and 19 deletions
+5 -17
View File
@@ -154,11 +154,6 @@ async def refund_wallet_endpoint(
key: ApiKey = await validate_bearer_key(bearer_value, session)
remaining_balance_msats: int = key.balance
refund_currency = key.refund_currency or "sat"
if refund_currency == "sat":
remaining_balance = remaining_balance_msats // 1000
else:
remaining_balance = remaining_balance_msats
if key.refund_currency == "sat":
remaining_balance = remaining_balance_msats // 1000
@@ -177,7 +172,7 @@ async def refund_wallet_endpoint(
await send_to_lnurl(
remaining_balance,
refund_currency,
key.refund_currency or "sat",
key.refund_mint_url or global_settings.primary_mint,
key.refund_address,
)
@@ -188,11 +183,11 @@ async def refund_wallet_endpoint(
remaining_balance, refund_currency, key.refund_mint_url
)
result = {"token": token}
if refund_currency == "sat":
result["sats"] = str(remaining_balance)
if key.refund_currency == "sat":
result["sats"] = str(remaining_balance_msats // 1000)
else:
result["msats"] = str(remaining_balance)
result["msats"] = str(remaining_balance_msats)
except HTTPException:
# Re-raise HTTP exceptions (like 400 for balance too small)
@@ -208,13 +203,6 @@ async def refund_wallet_endpoint(
):
raise HTTPException(status_code=503, detail="Mint service unavailable")
else:
from .core.logging import get_logger
logger = get_logger(__name__)
logger.error(
"Refund failed",
extra={"error": error_msg},
)
raise HTTPException(status_code=500, detail="Refund failed")
await _refund_cache_set(bearer_value, result)
Vendored
-1
Submodule vendor/cdk deleted from 52d796e9fe
Submodule vendor/cdk-python deleted from 915c6966b0