git.delta.rocks / unique-network / refs/commits / dbb52bba3658

difftreelog

fix use feature gate for foreign-assets gov

Daniel Shiposha2023-10-18parent: #9c50a8c.patch.diff
in: master

1 file changed

modifiedruntime/common/config/pallets/foreign_asset.rsdiffbeforeafterboth
4use staging_xcm::prelude::*;4use staging_xcm::prelude::*;
5use staging_xcm_builder::AccountKey20Aliases;5use staging_xcm_builder::AccountKey20Aliases;
6
7#[cfg(feature = "governance")]
8use crate::runtime_common::config::governance;
9
10#[cfg(not(feature = "governance"))]
11use frame_system::EnsureRoot;
612
7use crate::{13use crate::{
8 runtime_common::config::{14 runtime_common::config::{
9 ethereum::CrossAccountId as ConfigCrossAccountId,15 ethereum::CrossAccountId as ConfigCrossAccountId,
10 governance,
11 xcm::{LocationToAccountId, SelfLocation},16 xcm::{LocationToAccountId, SelfLocation},
12 },17 },
13 RelayNetwork, Runtime, RuntimeEvent,18 RelayNetwork, Runtime, RuntimeEvent,
36impl pallet_foreign_assets::Config for Runtime {41impl pallet_foreign_assets::Config for Runtime {
37 type RuntimeEvent = RuntimeEvent;42 type RuntimeEvent = RuntimeEvent;
43
44 #[cfg(feature = "governance")]
38 type ForceRegisterOrigin = governance::RootOrTechnicalCommitteeMember;45 type ForceRegisterOrigin = governance::RootOrTechnicalCommitteeMember;
46
47 #[cfg(not(feature = "governance"))]
48 type ForceRegisterOrigin = EnsureRoot<Self::AccountId>;
49
39 type PalletId = ForeignAssetPalletId;50 type PalletId = ForeignAssetPalletId;
40 type SelfLocation = SelfLocation;51 type SelfLocation = SelfLocation;