Skip to content

Commit f77ddfc

Browse files
committed
make pool members and stakers exclusive
1 parent 2b1739d commit f77ddfc

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

  • polkadot/runtime/westend/src

polkadot/runtime/westend/src/lib.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -648,6 +648,10 @@ impl pallet_staking::Config for Runtime {
648648
type EventListeners = (NominationPools, DelegatedStaking);
649649
type WeightInfo = weights::pallet_staking::WeightInfo<Runtime>;
650650
type DisablingStrategy = pallet_staking::UpToLimitDisablingStrategy;
651+
// Due to difference in how pools and staking pallets handle currency locks, we want to keep
652+
// pool members and stakers mutually exclusive. Hence, we prevent pool members from directly
653+
// staking.
654+
type Blacklist = pallet_nomination_pools::AllPoolMembers<Self>;
651655
}
652656

653657
impl pallet_fast_unstake::Config for Runtime {
@@ -1367,7 +1371,11 @@ impl pallet_nomination_pools::Config for Runtime {
13671371
type PalletId = PoolsPalletId;
13681372
type MaxPointsToBalance = MaxPointsToBalance;
13691373
type AdminOrigin = EitherOf<EnsureRoot<AccountId>, StakingAdmin>;
1370-
type Blacklist = Nothing;
1374+
// Due to difference in how pools and staking pallets handle currency locks, we want to keep
1375+
// pool members and stakers mutually exclusive. Hence, we want to prevent stakers from using
1376+
// the pool pallet. Any existing account that is already in the pool but blacklisted can still
1377+
// withdraw funds but cannot add new funds.
1378+
type Blacklist = pallet_staking::AllStakers<Self>;
13711379
}
13721380

13731381
parameter_types! {

0 commit comments

Comments
 (0)