Companion to #9514 (Remove Filter and use Contains instead) (#566)

* Remove Filter and use Contains instead

* Fixes

* Remove patch

* Bump Polkadot

* bump
This commit is contained in:
Gavin Wood
2021-08-09 18:07:37 +02:00
committed by GitHub
parent 6637471fb4
commit b3c38f0926
13 changed files with 298 additions and 309 deletions
+7 -7
View File
@@ -43,7 +43,7 @@ use codec::{Decode, Encode, MaxEncodedLen};
use constants::{currency::*, fee::WeightToFee};
use frame_support::{
construct_runtime, match_type, parameter_types,
traits::{All, Filter, InstanceFilter},
traits::{Everything, Contains, InstanceFilter},
weights::{
constants::{BlockExecutionWeight, ExtrinsicBaseWeight},
DispatchClass, IdentityFee, Weight,
@@ -144,8 +144,8 @@ parameter_types! {
}
pub struct BaseFilter;
impl Filter<Call> for BaseFilter {
fn filter(_c: &Call) -> bool { true }
impl Contains<Call> for BaseFilter {
fn contains(_c: &Call) -> bool { true }
}
// Configure FRAME pallets to include in runtime.
@@ -534,7 +534,7 @@ match_type! {
pub type Barrier = (
TakeWeightCredit,
AllowTopLevelPaidExecutionFrom<All<MultiLocation>>,
AllowTopLevelPaidExecutionFrom<Everything>,
AllowUnpaidExecutionFrom<ParentOrParentsExecutivePlurality>,
// ^^^ Parent and its exec plurality get free execution
);
@@ -576,10 +576,10 @@ impl pallet_xcm::Config for Runtime {
type SendXcmOrigin = EnsureXcmOrigin<Origin, LocalOriginToLocation>;
type XcmRouter = XcmRouter;
type ExecuteXcmOrigin = EnsureXcmOrigin<Origin, LocalOriginToLocation>;
type XcmExecuteFilter = All<(MultiLocation, Xcm<Call>)>;
type XcmExecuteFilter = Everything;
type XcmExecutor = XcmExecutor<XcmConfig>;
type XcmTeleportFilter = All<(MultiLocation, Vec<MultiAsset>)>;
type XcmReserveTransferFilter = All<(MultiLocation, Vec<MultiAsset>)>;
type XcmTeleportFilter = Everything;
type XcmReserveTransferFilter = Everything;
type Weigher = FixedWeightBounds<UnitWeightCost, Call>;
type LocationInverter = LocationInverter<Ancestry>;
}