schema update

This commit is contained in:
aecsocket
2026-07-13 20:47:35 +01:00
parent e47e1b7fe4
commit 656034fcef
2 changed files with 38 additions and 8 deletions
+15 -6
View File
@@ -119,14 +119,23 @@ impl PayoutsQueue {
.account_details
.wrap_err("source account does not have details")?;
let available = details
.balances
.balances_v2
.iter()
.map(|balance| {
if balance.token_symbol == muralpay::USDC {
balance.token_amount
} else {
Decimal::ZERO
.map(|balance| match balance {
muralpay::Balance::Blockchain {
token_symbol,
exponent,
value,
..
} if token_symbol == muralpay::USDC => {
*value * Decimal::new(1, *exponent)
}
muralpay::Balance::Fiat {
currency_symbol: muralpay::UsdSymbol::Usd,
exponent,
value,
} => *value * Decimal::new(1, *exponent),
_ => Decimal::ZERO,
})
.sum::<Decimal>();
Ok(AccountBalance {