diff --git a/pallets/sequencer-staking/src/lib.rs b/pallets/sequencer-staking/src/lib.rs index 53f66795f..d4bda257b 100644 --- a/pallets/sequencer-staking/src/lib.rs +++ b/pallets/sequencer-staking/src/lib.rs @@ -380,8 +380,9 @@ pub mod pallet { stake_amount: BalanceOf, alias_account: Option, stake_action: StakeAction, + sender: T::AccountId, ) -> DispatchResultWithPostInfo { - let sender = ensure_signed(origin)?; + let _ = ensure_root(origin)?; ensure!( !AliasAccountInUse::::contains_key(sender.clone()), @@ -468,8 +469,9 @@ pub mod pallet { pub fn rejoin_active_sequencers( origin: OriginFor, chain: T::ChainId, + sender: T::AccountId, ) -> DispatchResultWithPostInfo { - let sender = ensure_signed(origin)?; + let _ = ensure_root(origin)?; ensure!( !Self::is_active_sequencer(chain, &sender), Error::::SequencerAlreadyInActiveSet