Skip to content

Commit

Permalink
update origin
Browse files Browse the repository at this point in the history
  • Loading branch information
zqhxuyuan committed Feb 25, 2022
1 parent d1ad243 commit 4f9197b
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions xtokens/src/mock/para.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use crate as orml_xtokens;

use frame_support::{
construct_runtime, parameter_types,
traits::{EnsureOneOf, Everything, Get, Nothing},
traits::{Everything, Get, Nothing},
weights::{constants::WEIGHT_PER_SECOND, Weight},
};
use frame_system::EnsureRoot;
Expand All @@ -15,7 +15,7 @@ use sp_runtime::{
};

use cumulus_primitives_core::{ChannelStatus, GetChannelInfo, ParaId};
use pallet_xcm::{EnsureXcm, IsMajorityOfBody, XcmPassthrough};
use pallet_xcm::XcmPassthrough;
use polkadot_parachain::primitives::Sibling;
use xcm::latest::prelude::*;
use xcm_builder::{
Expand Down Expand Up @@ -128,7 +128,6 @@ pub type XcmOriginToCallOrigin = (
parameter_types! {
pub const UnitWeightCost: Weight = 10;
pub const MaxInstructions: u32 = 100;
pub const ExecutiveBody: BodyId = BodyId::Executive;
}

pub type LocalAssetTransactor = MultiCurrencyAdapter<
Expand Down Expand Up @@ -222,8 +221,7 @@ impl cumulus_pallet_xcmp_queue::Config for Runtime {
type ChannelInfo = ChannelInfo;
type VersionWrapper = ();
type ExecuteOverweightOrigin = EnsureRoot<AccountId>;
type ControllerOrigin =
EnsureOneOf<EnsureRoot<AccountId>, EnsureXcm<IsMajorityOfBody<RelayLocation, ExecutiveBody>>>;
type ControllerOrigin = EnsureRoot<AccountId>;
type ControllerOriginConverter = XcmOriginToCallOrigin;
}

Expand Down

0 comments on commit 4f9197b

Please sign in to comment.