diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index b5ddb16a2800..adf41fd5ab14 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -41,13 +41,13 @@ use frame_election_provider_support::{generate_solution_type, onchain, Sequentia use frame_support::{ construct_runtime, parameter_types, traits::{ - ConstU32, EitherOfDiverse, InstanceFilter, KeyOwnerProofSystem, LockIdentifier, + ConstU32, EitherOf, EitherOfDiverse, InstanceFilter, KeyOwnerProofSystem, LockIdentifier, PrivilegeCmp, WithdrawReasons, }, weights::ConstantMultiplier, PalletId, RuntimeDebug, }; -use frame_system::EnsureRoot; +use frame_system::{EnsureRoot, EnsureWithSuccess}; use pallet_grandpa::{fg_primitives, AuthorityId as GrandpaId}; use pallet_im_online::sr25519::AuthorityId as ImOnlineId; use pallet_session::historical as session_historical; @@ -826,6 +826,7 @@ parameter_types! { pub const MaxPeerInHeartbeats: u32 = 10_000; pub const MaxPeerDataEncodingSize: u32 = 1_000; pub const RootSpendOriginMaxAmount: Balance = Balance::MAX; + pub const CouncilSpendOriginMaxAmount: Balance = Balance::MAX; } type ApproveOrigin = EitherOfDiverse< @@ -849,7 +850,14 @@ impl pallet_treasury::Config for Runtime { type SpendFunds = Bounties; type MaxApprovals = MaxApprovals; type WeightInfo = weights::pallet_treasury::WeightInfo; - type SpendOrigin = frame_system::EnsureRootWithSuccess; + type SpendOrigin = EitherOf< + frame_system::EnsureRootWithSuccess, + EnsureWithSuccess< + pallet_collective::EnsureProportionAtLeast, + AccountId, + CouncilSpendOriginMaxAmount, + >, + >; } parameter_types! {