Unverified Commit f930c7bd authored by Shawn Tabrizi's avatar Shawn Tabrizi Committed by GitHub
Browse files

Companion for #6511 (#1321)

* Add custom runtime upgrade for retract tip

* cargo update -p sp-io
parent d1ce3733
Pipeline #98833 passed with stages
in 24 minutes and 11 seconds
......@@ -880,6 +880,14 @@ impl proxy::Trait for Runtime {
type MaxProxies = MaxProxies;
}
pub struct CustomOnRuntimeUpgrade;
impl frame_support::traits::OnRuntimeUpgrade for CustomOnRuntimeUpgrade {
fn on_runtime_upgrade() -> frame_support::weights::Weight {
treasury::Module::<Runtime>::migrate_retract_tip_for_tip_new();
500_000_000
}
}
construct_runtime! {
pub enum Runtime where
Block = Block,
......@@ -981,7 +989,14 @@ pub type UncheckedExtrinsic = generic::UncheckedExtrinsic<Address, Call, Signatu
/// Extrinsic type that has already been checked.
pub type CheckedExtrinsic = generic::CheckedExtrinsic<AccountId, Nonce, Call>;
/// Executive: handles dispatch to the various modules.
pub type Executive = executive::Executive<Runtime, Block, system::ChainContext<Runtime>, Runtime, AllModules>;
pub type Executive = executive::Executive<
Runtime,
Block,
system::ChainContext<Runtime>,
Runtime,
AllModules,
CustomOnRuntimeUpgrade
>;
/// The payload being signed in the transactions.
pub type SignedPayload = generic::SignedPayload<Call, SignedExtra>;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment