Replace T::AccountId with <T::Lookup as StaticLookup>::Source (#11670)

* initial

* update

* update

* update

* cargo fmt

* update

* update benchmarks

* AccountIdLookupOf<T>

* cargo fmt

* fix conflits

* cargo fmt

* update

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
This commit is contained in:
DoordashconandOliver Tale-Yazdi authored and GitHub committed 2022-08-18 09:30:46 +00:00
1 parent 511e5c9651
commit d46f6f0d34
50 files changed
+465 -309

No files matched your search

+3 -2
View File
@@ -110,6 +110,7 @@ use sp_std::{fmt::Debug, prelude::*};
type BalanceOf<T, I> =
<<T as Config<I>>::Currency as Currency<<T as frame_system::Config>::AccountId>>::Balance;
type PoolT<T, I> = Vec<(<T as frame_system::Config>::AccountId, Option<<T as Config<I>>::Score>)>;
type AccountIdLookupOf<T> = <<T as frame_system::Config>::Lookup as StaticLookup>::Source;
/// The enum is supplied when refreshing the members set.
/// Depending on the enum variant the corresponding associated
@@ -346,7 +347,7 @@ pub mod pallet {
#[pallet::weight(0)]
pub fn kick(
origin: OriginFor<T>,
dest: <T::Lookup as StaticLookup>::Source,
dest: AccountIdLookupOf<T>,
index: u32,
) -> DispatchResult {
T::KickOrigin::ensure_origin(origin)?;
@@ -370,7 +371,7 @@ pub mod pallet {
#[pallet::weight(0)]
pub fn score(
origin: OriginFor<T>,
dest: <T::Lookup as StaticLookup>::Source,
dest: AccountIdLookupOf<T>,
index: u32,
score: T::Score,
) -> DispatchResult {