From 36ad58a4fd5b418664f60e0c3dceb1932f18f949 Mon Sep 17 00:00:00 2001 From: Dino Pacandi Date: Wed, 20 Nov 2024 09:50:49 +0100 Subject: [PATCH] Allow EVM accounts to participate --- runtime/astar/src/lib.rs | 3 ++- runtime/astar/src/precompiles.rs | 5 +++++ runtime/local/src/lib.rs | 3 ++- runtime/local/src/precompiles.rs | 4 ++++ runtime/shibuya/src/lib.rs | 3 ++- runtime/shibuya/src/precompiles.rs | 5 +++++ 6 files changed, 20 insertions(+), 3 deletions(-) diff --git a/runtime/astar/src/lib.rs b/runtime/astar/src/lib.rs index e8965f036..2470d17d1 100644 --- a/runtime/astar/src/lib.rs +++ b/runtime/astar/src/lib.rs @@ -1469,7 +1469,8 @@ impl InstanceFilter for CommunityCouncilCallFilter { c, RuntimeCall::DappStaking(..) | RuntimeCall::System(frame_system::Call::remark { .. }) - | RuntimeCall::Utility(..) + | RuntimeCall::Utility(pallet_utility::Call::batch { .. }) + | RuntimeCall::Utility(pallet_utility::Call::batch_all { .. }) ) } } diff --git a/runtime/astar/src/precompiles.rs b/runtime/astar/src/precompiles.rs index c2d85d001..6ee6e1391 100644 --- a/runtime/astar/src/precompiles.rs +++ b/runtime/astar/src/precompiles.rs @@ -63,6 +63,11 @@ impl Contains for WhitelistedCalls { RuntimeCall::Assets(pallet_assets::Call::transfer { .. }) => true, RuntimeCall::XTokens(orml_xtokens::Call::transfer_multiasset_with_fee { .. }) => true, RuntimeCall::XTokens(orml_xtokens::Call::transfer_multiasset { .. }) => true, + // Governance related calls + RuntimeCall::Democracy(_) + | RuntimeCall::Treasury(_) + | RuntimeCall::CommunityTreasury(_) + | RuntimeCall::Preimage(_) => true, _ => false, } } diff --git a/runtime/local/src/lib.rs b/runtime/local/src/lib.rs index 185347545..650698f91 100644 --- a/runtime/local/src/lib.rs +++ b/runtime/local/src/lib.rs @@ -1112,7 +1112,8 @@ impl InstanceFilter for CommunityCouncilCallFilter { c, RuntimeCall::DappStaking(..) | RuntimeCall::System(frame_system::Call::remark { .. }) - | RuntimeCall::Utility(..) + | RuntimeCall::Utility(pallet_utility::Call::batch { .. }) + | RuntimeCall::Utility(pallet_utility::Call::batch_all { .. }) ) } } diff --git a/runtime/local/src/precompiles.rs b/runtime/local/src/precompiles.rs index 0daf444b5..8a29d1ab7 100644 --- a/runtime/local/src/precompiles.rs +++ b/runtime/local/src/precompiles.rs @@ -61,6 +61,10 @@ impl Contains for WhitelistedCalls { } RuntimeCall::DappStaking(_) => true, RuntimeCall::Assets(pallet_assets::Call::transfer { .. }) => true, + RuntimeCall::Democracy(_) + | RuntimeCall::Treasury(_) + | RuntimeCall::CommunityTreasury(_) + | RuntimeCall::Preimage(_) => true, _ => false, } } diff --git a/runtime/shibuya/src/lib.rs b/runtime/shibuya/src/lib.rs index ada15891d..39829378a 100644 --- a/runtime/shibuya/src/lib.rs +++ b/runtime/shibuya/src/lib.rs @@ -1501,7 +1501,8 @@ impl InstanceFilter for CommunityCouncilCallFilter { c, RuntimeCall::DappStaking(..) | RuntimeCall::System(frame_system::Call::remark { .. }) - | RuntimeCall::Utility(..) + | RuntimeCall::Utility(pallet_utility::Call::batch { .. }) + | RuntimeCall::Utility(pallet_utility::Call::batch_all { .. }) ) } } diff --git a/runtime/shibuya/src/precompiles.rs b/runtime/shibuya/src/precompiles.rs index 642e7e491..19a413321 100644 --- a/runtime/shibuya/src/precompiles.rs +++ b/runtime/shibuya/src/precompiles.rs @@ -64,6 +64,11 @@ impl Contains for WhitelistedCalls { RuntimeCall::Assets(pallet_assets::Call::transfer { .. }) => true, RuntimeCall::XTokens(orml_xtokens::Call::transfer_multiasset_with_fee { .. }) => true, RuntimeCall::XTokens(orml_xtokens::Call::transfer_multiasset { .. }) => true, + // Governance related calls + RuntimeCall::Democracy(_) + | RuntimeCall::Treasury(_) + | RuntimeCall::CommunityTreasury(_) + | RuntimeCall::Preimage(_) => true, _ => false, } }