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
+3 -3
View File
@@ -31,7 +31,7 @@ use frame_support::{
dispatch::{DispatchError, DispatchResult},
ensure,
traits::{
fungible, fungibles, fungibles::Lockable, Currency, Get, PollStatus, Polling,
fungible, Currency, Get, LockIdentifier, LockableCurrency, PollStatus, Polling,
ReservableCurrency, WithdrawReasons,
},
};
@@ -60,7 +60,7 @@ mod tests;
#[cfg(feature = "runtime-benchmarks")]
pub mod benchmarking;
const CONVICTION_VOTING_ID: fungibles::LockIdentifier = *b"pyconvot";
const CONVICTION_VOTING_ID: LockIdentifier = *b"pyconvot";
type AccountIdLookupOf<T> = <<T as frame_system::Config>::Lookup as StaticLookup>::Source;
type BalanceOf<T, I = ()> =
@@ -104,7 +104,7 @@ pub mod pallet {
type WeightInfo: WeightInfo;
/// Currency type with which voting happens.
type Currency: ReservableCurrency<Self::AccountId>
+ fungibles::Lockable<Self::AccountId, Moment = Self::BlockNumber>
+ LockableCurrency<Self::AccountId, Moment = Self::BlockNumber>
+ fungible::Inspect<Self::AccountId>;
/// The implementation of the logic which conducts polls.