From 87ff2cf20ab25fd00d23fa6d597442e653e95d5a Mon Sep 17 00:00:00 2001 From: Fredrik Simonsson Date: Mon, 26 Feb 2024 13:03:13 +0900 Subject: [PATCH] Update after review --- runtimes/eden/src/lib.rs | 4 +--- runtimes/eden/src/migrations.rs | 6 +++++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/runtimes/eden/src/lib.rs b/runtimes/eden/src/lib.rs index d55673aad11..cb6e4b57e0a 100644 --- a/runtimes/eden/src/lib.rs +++ b/runtimes/eden/src/lib.rs @@ -34,8 +34,6 @@ pub fn wasm_binary_unwrap() -> &'static [u8] { ) } -use core::u64; - use constants::RuntimeBlockWeights; use frame_support::{construct_runtime, weights::Weight}; use pallet_transaction_payment::{FeeDetails, RuntimeDispatchInfo}; @@ -193,7 +191,7 @@ pub type Migrations = ( pallet_contracts::Migration, // Run custom migrations // - // For polkadot 1.5.0 + // For polkadot 1.6.0 cumulus_pallet_xcmp_queue::migration::v4::MigrationToV4, pallet_identity::migration::v1::VersionUncheckedMigrateV0ToV1, migrations::MultiMigration, diff --git a/runtimes/eden/src/migrations.rs b/runtimes/eden/src/migrations.rs index efa100beb2c..ba39113789b 100644 --- a/runtimes/eden/src/migrations.rs +++ b/runtimes/eden/src/migrations.rs @@ -53,8 +53,8 @@ where // Storage migration `pallet_identity::migration::v1::VersionUncheckedMigrateV0ToV1,` does not update // StorageVersion on chain. - StorageVersion::new(1).put::>(); + T::DbWeight::get().writes(11) } @@ -68,6 +68,10 @@ where StorageVersion::get::>() == 0, TryRuntimeError::Other("pallet_uniques storage version is not 0") ); + ensure!( + StorageVersion::get::>() == 0, + TryRuntimeError::Other("pallet_identity storage version is not 0") + ); Ok(vec![]) }