diff --git a/pallet/staking/src/benchmarking.rs b/pallet/staking/src/benchmarking.rs index b4c6bae7d..342e4f6c2 100644 --- a/pallet/staking/src/benchmarking.rs +++ b/pallet/staking/src/benchmarking.rs @@ -29,6 +29,8 @@ use sp_std::prelude::*; mod benchmarks { // darwinia use super::*; + // substrate + use frame_support::traits::Currency; fn deposit_for(who: &T::AccountId, count: u32) -> Vec> where @@ -53,7 +55,7 @@ mod benchmarks { let a = frame_benchmarking::whitelisted_caller(); // Remove `+ 1` after https://github.com/paritytech/substrate/pull/13655. - T::RingCurrency::make_free_balance_be(&a, 1_024 * UNIT + 1); + ::Ring::make_free_balance_be(&a, 1_024 * UNIT + 1); ::Kton::mint(&a, UNIT).unwrap(); let deposits = deposit_for::(&a, x); @@ -70,7 +72,7 @@ mod benchmarks { let a = frame_benchmarking::whitelisted_caller(); // Remove `+ 1` after https://github.com/paritytech/substrate/pull/13655. - T::RingCurrency::make_free_balance_be(&a, 1_024 * UNIT + 1); + ::Ring::make_free_balance_be(&a, 1_024 * UNIT + 1); ::Kton::mint(&a, UNIT).unwrap(); let deposits = deposit_for::(&a, x); @@ -90,7 +92,7 @@ mod benchmarks { let a = frame_benchmarking::whitelisted_caller(); // Remove `+ 1` after https://github.com/paritytech/substrate/pull/13655. - T::RingCurrency::make_free_balance_be(&a, 1_024 * UNIT + 1); + ::Ring::make_free_balance_be(&a, 1_024 * UNIT + 1); ::Kton::mint(&a, UNIT).unwrap(); let deposits = deposit_for::(&a, x); @@ -112,7 +114,7 @@ mod benchmarks { let a = frame_benchmarking::whitelisted_caller(); // Remove `+ 1` after https://github.com/paritytech/substrate/pull/13655. - T::RingCurrency::make_free_balance_be(&a, 1_024 * UNIT + 1); + ::Ring::make_free_balance_be(&a, 1_024 * UNIT + 1); ::Kton::mint(&a, UNIT).unwrap(); let deposits = deposit_for::(&a, ::MaxUnstakings::get()); @@ -154,7 +156,7 @@ mod benchmarks { let a_cloned = a.clone(); // Remove `+ 1` after https://github.com/paritytech/substrate/pull/13655. - T::RingCurrency::make_free_balance_be(&a, UNIT + 1); + ::Ring::make_free_balance_be(&a, UNIT + 1); >::stake( RawOrigin::Signed(a.clone()).into(), @@ -177,7 +179,7 @@ mod benchmarks { let a = frame_benchmarking::whitelisted_caller::(); // Remove `+ 1` after https://github.com/paritytech/substrate/pull/13655. - T::RingCurrency::make_free_balance_be(&a, UNIT + 1); + ::Ring::make_free_balance_be(&a, UNIT + 1); >::stake( RawOrigin::Signed(a.clone()).into(),