From 5c29c481d8f6f5549b363d65e73810534af6000e Mon Sep 17 00:00:00 2001 From: Vic Genin Date: Sat, 20 Jul 2024 08:24:53 +0300 Subject: [PATCH] align cere/dev migrations --- runtime/cere-dev/src/lib.rs | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/runtime/cere-dev/src/lib.rs b/runtime/cere-dev/src/lib.rs index 03069a061..6e5ec7044 100644 --- a/runtime/cere-dev/src/lib.rs +++ b/runtime/cere-dev/src/lib.rs @@ -315,20 +315,20 @@ impl InstanceFilter for ProxyType { ProxyType::Any => true, ProxyType::NonTransfer => !matches!( c, - RuntimeCall::Balances(..) | - RuntimeCall::Vesting(pallet_vesting::Call::vested_transfer { .. }) | - RuntimeCall::Indices(pallet_indices::Call::transfer { .. }) | - RuntimeCall::NominationPools(..) | - RuntimeCall::ConvictionVoting(..) | - RuntimeCall::Referenda(..) | - RuntimeCall::Whitelist(..) + RuntimeCall::Balances(..) + | RuntimeCall::Vesting(pallet_vesting::Call::vested_transfer { .. }) + | RuntimeCall::Indices(pallet_indices::Call::transfer { .. }) + | RuntimeCall::NominationPools(..) + | RuntimeCall::ConvictionVoting(..) + | RuntimeCall::Referenda(..) + | RuntimeCall::Whitelist(..) ), ProxyType::Governance => matches!( c, - RuntimeCall::Treasury(..) | - RuntimeCall::ConvictionVoting(..) | - RuntimeCall::Referenda(..) | - RuntimeCall::Whitelist(..) + RuntimeCall::Treasury(..) + | RuntimeCall::ConvictionVoting(..) + | RuntimeCall::Referenda(..) + | RuntimeCall::Whitelist(..) ), ProxyType::Staking => matches!(c, RuntimeCall::Staking(..)), } @@ -669,8 +669,8 @@ impl Get> for OffchainRandomBalancing { max => { let seed = sp_io::offchain::random_seed(); let random = ::decode(&mut TrailingZeroInput::new(&seed)) - .expect("input is padded with zeroes; qed") % - max.saturating_add(1); + .expect("input is padded with zeroes; qed") + % max.saturating_add(1); random as usize }, }; @@ -1376,7 +1376,11 @@ pub type SignedPayload = generic::SignedPayload; pub type CheckedExtrinsic = generic::CheckedExtrinsic; /// Runtime migrations -type Migrations = (pallet_ddc_customers::migration::MigrateToV2,); +type Migrations = ( + pallet_ddc_clusters::migrations::v2::MigrateToV2, + pallet_ddc_staking::migrations::v1::MigrateToV1, + pallet_ddc_customers::migration::MigrateToV1, +); /// Executive: handles dispatch to the various modules. pub type Executive = frame_executive::Executive<