Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Fix staking genesis build (#14140)
Browse files Browse the repository at this point in the history
Cumulus CI is stuck in paritytech/cumulus#2574, so companion check will be red.
Changes_
- Controller not needed

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
  • Loading branch information
ggwpez authored May 15, 2023
1 parent 1f9e3aa commit 3919ca8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions frame/staking/src/pallet/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -631,7 +631,7 @@ pub mod pallet {
MaxNominatorsCount::<T>::put(x);
}

for &(ref stash, ref controller, balance, ref status) in &self.stakers {
for &(ref stash, _, balance, ref status) in &self.stakers {
crate::log!(
trace,
"inserting genesis staker: {:?} => {:?} => {:?}",
Expand All @@ -650,11 +650,11 @@ pub mod pallet {
));
frame_support::assert_ok!(match status {
crate::StakerStatus::Validator => <Pallet<T>>::validate(
T::RuntimeOrigin::from(Some(controller.clone()).into()),
T::RuntimeOrigin::from(Some(stash.clone()).into()),
Default::default(),
),
crate::StakerStatus::Nominator(votes) => <Pallet<T>>::nominate(
T::RuntimeOrigin::from(Some(controller.clone()).into()),
T::RuntimeOrigin::from(Some(stash.clone()).into()),
votes.iter().map(|l| T::Lookup::unlookup(l.clone())).collect(),
),
_ => Ok(()),
Expand Down

0 comments on commit 3919ca8

Please sign in to comment.