mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 20:27:58 +00:00
Remove u32_trait (#10850)
* Remove `u32_trait` This trait only existed because there wasn't any const generic support at time of creation. However, we now have support for it :) * FMT
This commit is contained in:
@@ -53,11 +53,7 @@ pub use pallet_transaction_payment::{CurrencyAdapter, Multiplier, TargetedFeeAdj
|
||||
use pallet_transaction_payment::{FeeDetails, RuntimeDispatchInfo};
|
||||
use sp_api::impl_runtime_apis;
|
||||
use sp_authority_discovery::AuthorityId as AuthorityDiscoveryId;
|
||||
use sp_core::{
|
||||
crypto::KeyTypeId,
|
||||
u32_trait::{_1, _2, _3, _4, _5},
|
||||
OpaqueMetadata,
|
||||
};
|
||||
use sp_core::{crypto::KeyTypeId, OpaqueMetadata};
|
||||
use sp_inherents::{CheckInherentsResult, InherentData};
|
||||
use sp_runtime::{
|
||||
create_runtime_str,
|
||||
@@ -550,7 +546,7 @@ impl pallet_staking::Config for Runtime {
|
||||
/// A super-majority of the council can cancel the slash.
|
||||
type SlashCancelOrigin = EnsureOneOf<
|
||||
EnsureRoot<AccountId>,
|
||||
pallet_collective::EnsureProportionAtLeast<_3, _4, AccountId, CouncilCollective>,
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, CouncilCollective, 3, 4>,
|
||||
>;
|
||||
type SessionInterface = Self;
|
||||
type EraPayout = pallet_staking::ConvertCurve<RewardCurve>;
|
||||
@@ -796,30 +792,30 @@ impl pallet_democracy::Config for Runtime {
|
||||
type MinimumDeposit = MinimumDeposit;
|
||||
/// A straight majority of the council can decide what their next motion is.
|
||||
type ExternalOrigin =
|
||||
pallet_collective::EnsureProportionAtLeast<_1, _2, AccountId, CouncilCollective>;
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, CouncilCollective, 1, 2>;
|
||||
/// A super-majority can have the next scheduled referendum be a straight majority-carries vote.
|
||||
type ExternalMajorityOrigin =
|
||||
pallet_collective::EnsureProportionAtLeast<_3, _4, AccountId, CouncilCollective>;
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, CouncilCollective, 3, 4>;
|
||||
/// A unanimous council can have the next scheduled referendum be a straight default-carries
|
||||
/// (NTB) vote.
|
||||
type ExternalDefaultOrigin =
|
||||
pallet_collective::EnsureProportionAtLeast<_1, _1, AccountId, CouncilCollective>;
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, CouncilCollective, 1, 1>;
|
||||
/// Two thirds of the technical committee can have an ExternalMajority/ExternalDefault vote
|
||||
/// be tabled immediately and with a shorter voting/enactment period.
|
||||
type FastTrackOrigin =
|
||||
pallet_collective::EnsureProportionAtLeast<_2, _3, AccountId, TechnicalCollective>;
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, TechnicalCollective, 2, 3>;
|
||||
type InstantOrigin =
|
||||
pallet_collective::EnsureProportionAtLeast<_1, _1, AccountId, TechnicalCollective>;
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, TechnicalCollective, 1, 1>;
|
||||
type InstantAllowed = frame_support::traits::ConstBool<true>;
|
||||
type FastTrackVotingPeriod = FastTrackVotingPeriod;
|
||||
// To cancel a proposal which has been passed, 2/3 of the council must agree to it.
|
||||
type CancellationOrigin =
|
||||
pallet_collective::EnsureProportionAtLeast<_2, _3, AccountId, CouncilCollective>;
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, CouncilCollective, 2, 3>;
|
||||
// To cancel a proposal before it has been passed, the technical committee must be unanimous or
|
||||
// Root must agree.
|
||||
type CancelProposalOrigin = EnsureOneOf<
|
||||
EnsureRoot<AccountId>,
|
||||
pallet_collective::EnsureProportionAtLeast<_1, _1, AccountId, TechnicalCollective>,
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, TechnicalCollective, 1, 1>,
|
||||
>;
|
||||
type BlacklistOrigin = EnsureRoot<AccountId>;
|
||||
// Any single technical committee member may veto a coming council proposal, however they can
|
||||
@@ -909,7 +905,7 @@ impl pallet_collective::Config<TechnicalCollective> for Runtime {
|
||||
|
||||
type EnsureRootOrHalfCouncil = EnsureOneOf<
|
||||
EnsureRoot<AccountId>,
|
||||
pallet_collective::EnsureProportionMoreThan<_1, _2, AccountId, CouncilCollective>,
|
||||
pallet_collective::EnsureProportionMoreThan<AccountId, CouncilCollective, 1, 2>,
|
||||
>;
|
||||
impl pallet_membership::Config<pallet_membership::Instance1> for Runtime {
|
||||
type Event = Event;
|
||||
@@ -951,11 +947,11 @@ impl pallet_treasury::Config for Runtime {
|
||||
type Currency = Balances;
|
||||
type ApproveOrigin = EnsureOneOf<
|
||||
EnsureRoot<AccountId>,
|
||||
pallet_collective::EnsureProportionAtLeast<_3, _5, AccountId, CouncilCollective>,
|
||||
pallet_collective::EnsureProportionAtLeast<AccountId, CouncilCollective, 3, 5>,
|
||||
>;
|
||||
type RejectOrigin = EnsureOneOf<
|
||||
EnsureRoot<AccountId>,
|
||||
pallet_collective::EnsureProportionMoreThan<_1, _2, AccountId, CouncilCollective>,
|
||||
pallet_collective::EnsureProportionMoreThan<AccountId, CouncilCollective, 1, 2>,
|
||||
>;
|
||||
type Event = Event;
|
||||
type OnSlash = ();
|
||||
@@ -1226,7 +1222,7 @@ impl pallet_society::Config for Runtime {
|
||||
type RotationPeriod = RotationPeriod;
|
||||
type MaxLockDuration = MaxLockDuration;
|
||||
type FounderSetOrigin =
|
||||
pallet_collective::EnsureProportionMoreThan<_1, _2, AccountId, CouncilCollective>;
|
||||
pallet_collective::EnsureProportionMoreThan<AccountId, CouncilCollective, 1, 2>;
|
||||
type SuspensionJudgementOrigin = pallet_society::EnsureFounder<Runtime>;
|
||||
type MaxCandidateIntake = MaxCandidateIntake;
|
||||
type ChallengePeriod = ChallengePeriod;
|
||||
|
||||
Reference in New Issue
Block a user