Skip to content
This repository has been archived by the owner on Apr 1, 2024. It is now read-only.

Commit

Permalink
fix: evm reducible is usable()
Browse files Browse the repository at this point in the history
  • Loading branch information
alstjd0921 committed Oct 24, 2023
1 parent cf91023 commit 60cd620
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions frame/balances/src/impl_fungible.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,7 @@ impl<T: Config<I>, I: 'static> fungible::Inspect<T::AccountId> for Pallet<T, I>
preservation: Preservation,
force: Fortitude,
) -> Self::Balance {
let a = Self::account(who);
let mut untouchable = Zero::zero();
if force == Polite {
// Frozen balance applies to total. Anything on hold therefore gets discounted from the
// limit given by the freezes.
untouchable = a.frozen.saturating_add(a.reserved);
}
// Liquid balance is what is neither on hold nor frozen/required for provider.
a.free.saturating_sub(untouchable)
Self::account(who).usable()
}
fn can_deposit(
who: &T::AccountId,
Expand Down

0 comments on commit 60cd620

Please sign in to comment.