Revert "Move LockableCurrency trait to fungibles::Lockable and deprecate LockableCurrency (#12798)" (#12882)

This reverts commit 9a014d1ecd.
This commit is contained in:
Anthony Alaribe
2022-12-09 11:40:59 +02:00
committed by GitHub
parent 8a24e27377
commit 96902eae48
20 changed files with 105 additions and 135 deletions
+2 -3
View File
@@ -25,9 +25,8 @@ use frame_support::{
dispatch::WithPostDispatchInfo,
pallet_prelude::*,
traits::{
fungibles::Lockable, Currency, CurrencyToVote, Defensive, DefensiveResult,
EstimateNextNewSession, Get, Imbalance, OnUnbalanced, TryCollect, UnixTime,
WithdrawReasons,
Currency, CurrencyToVote, Defensive, DefensiveResult, EstimateNextNewSession, Get,
Imbalance, LockableCurrency, OnUnbalanced, TryCollect, UnixTime, WithdrawReasons,
},
weights::Weight,
};
+4 -4
View File
@@ -24,8 +24,8 @@ use frame_support::{
dispatch::Codec,
pallet_prelude::*,
traits::{
fungibles, fungibles::Lockable, Currency, CurrencyToVote, Defensive, DefensiveResult,
DefensiveSaturating, EnsureOrigin, EstimateNextNewSession, Get, OnUnbalanced, TryCollect,
Currency, CurrencyToVote, Defensive, DefensiveResult, DefensiveSaturating, EnsureOrigin,
EstimateNextNewSession, Get, LockIdentifier, LockableCurrency, OnUnbalanced, TryCollect,
UnixTime,
},
weights::Weight,
@@ -50,7 +50,7 @@ use crate::{
ValidatorPrefs,
};
const STAKING_ID: fungibles::LockIdentifier = *b"staking ";
const STAKING_ID: LockIdentifier = *b"staking ";
#[frame_support::pallet]
pub mod pallet {
@@ -78,7 +78,7 @@ pub mod pallet {
#[pallet::config]
pub trait Config: frame_system::Config {
/// The staking balance.
type Currency: fungibles::Lockable<
type Currency: LockableCurrency<
Self::AccountId,
Moment = Self::BlockNumber,
Balance = Self::CurrencyBalance,