mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-20 02:21:03 +00:00
remove stale migrations (#5694)
* polkadot: remove stale migrations * kusama: remove stale migrations
This commit is contained in:
@@ -1600,30 +1600,11 @@ pub type Executive = frame_executive::Executive<
|
|||||||
frame_system::ChainContext<Runtime>,
|
frame_system::ChainContext<Runtime>,
|
||||||
Runtime,
|
Runtime,
|
||||||
AllPalletsWithSystem,
|
AllPalletsWithSystem,
|
||||||
(
|
(),
|
||||||
RenameBagsListToVoterList,
|
|
||||||
pallet_bags_list::migrations::AddScore<Runtime>,
|
|
||||||
pallet_nomination_pools::migration::v1::MigrateToV1<Runtime>,
|
|
||||||
),
|
|
||||||
>;
|
>;
|
||||||
/// The payload being signed in the transactions.
|
/// The payload being signed in the transactions.
|
||||||
pub type SignedPayload = generic::SignedPayload<Call, SignedExtra>;
|
pub type SignedPayload = generic::SignedPayload<Call, SignedExtra>;
|
||||||
|
|
||||||
/// A migration which renames the pallet `BagsList` to `VoterList`
|
|
||||||
pub struct RenameBagsListToVoterList;
|
|
||||||
impl frame_support::traits::OnRuntimeUpgrade for RenameBagsListToVoterList {
|
|
||||||
#[cfg(feature = "try-runtime")]
|
|
||||||
fn pre_upgrade() -> Result<(), &'static str> {
|
|
||||||
// For other pre-upgrade checks, we need the storage to already be migrated.
|
|
||||||
frame_support::storage::migration::move_pallet(b"BagsList", b"VoterList");
|
|
||||||
Ok(())
|
|
||||||
}
|
|
||||||
fn on_runtime_upgrade() -> frame_support::weights::Weight {
|
|
||||||
frame_support::storage::migration::move_pallet(b"BagsList", b"VoterList");
|
|
||||||
frame_support::weights::Weight::MAX
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
#[cfg(feature = "runtime-benchmarks")]
|
#[cfg(feature = "runtime-benchmarks")]
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate frame_benchmarking;
|
extern crate frame_benchmarking;
|
||||||
|
|||||||
@@ -1515,26 +1515,11 @@ pub type Executive = frame_executive::Executive<
|
|||||||
frame_system::ChainContext<Runtime>,
|
frame_system::ChainContext<Runtime>,
|
||||||
Runtime,
|
Runtime,
|
||||||
AllPalletsWithSystem,
|
AllPalletsWithSystem,
|
||||||
(RenameBagsListToVoterList, pallet_bags_list::migrations::AddScore<Runtime>),
|
(),
|
||||||
>;
|
>;
|
||||||
/// The payload being signed in transactions.
|
/// The payload being signed in transactions.
|
||||||
pub type SignedPayload = generic::SignedPayload<Call, SignedExtra>;
|
pub type SignedPayload = generic::SignedPayload<Call, SignedExtra>;
|
||||||
|
|
||||||
/// A migration which renames the pallet `BagsList` to `VoterList`
|
|
||||||
pub struct RenameBagsListToVoterList;
|
|
||||||
impl frame_support::traits::OnRuntimeUpgrade for RenameBagsListToVoterList {
|
|
||||||
#[cfg(feature = "try-runtime")]
|
|
||||||
fn pre_upgrade() -> Result<(), &'static str> {
|
|
||||||
// For other pre-upgrade checks, we need the storage to already be migrated.
|
|
||||||
frame_support::storage::migration::move_pallet(b"BagsList", b"VoterList");
|
|
||||||
Ok(())
|
|
||||||
}
|
|
||||||
fn on_runtime_upgrade() -> frame_support::weights::Weight {
|
|
||||||
frame_support::storage::migration::move_pallet(b"BagsList", b"VoterList");
|
|
||||||
frame_support::weights::Weight::MAX
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
#[cfg(feature = "runtime-benchmarks")]
|
#[cfg(feature = "runtime-benchmarks")]
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate frame_benchmarking;
|
extern crate frame_benchmarking;
|
||||||
|
|||||||
Reference in New Issue
Block a user