You've already forked AstralRinth
forked from didirus/AstralRinth
chore(clippy): enable and fix many stricter lints (#3783)
* chore(clippy): enable and fix many stricter lints These ensure that the codebase uses more idiomatic, performant, and concise language constructions. * chore: make non-Clippy compiler warnings also deny by default
This commit is contained in:
committed by
GitHub
parent
301967d204
commit
f84f8c1c2b
@@ -830,14 +830,13 @@ async fn get_user_balance(
|
||||
.fetch_optional(pool)
|
||||
.await?;
|
||||
|
||||
let (withdrawn, fees) = withdrawn
|
||||
.map(|x| {
|
||||
let (withdrawn, fees) =
|
||||
withdrawn.map_or((Decimal::ZERO, Decimal::ZERO), |x| {
|
||||
(
|
||||
x.amount.unwrap_or(Decimal::ZERO),
|
||||
x.fee.unwrap_or(Decimal::ZERO),
|
||||
)
|
||||
})
|
||||
.unwrap_or((Decimal::ZERO, Decimal::ZERO));
|
||||
});
|
||||
|
||||
Ok(UserBalance {
|
||||
available: available.round_dp(16)
|
||||
|
||||
Reference in New Issue
Block a user