Skip to content

Commit

Permalink
Remove testing functions
Browse files Browse the repository at this point in the history
  • Loading branch information
PolkadotDom committed Dec 25, 2024
1 parent 331469e commit 5cea0ca
Showing 1 changed file with 0 additions and 26 deletions.
26 changes: 0 additions & 26 deletions substrate/frame/salary/src/migration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,19 +80,6 @@ pub mod v1 {
where
BC: ConvertBlockNumber<LocalBlockNumberFor<T>, NewBlockNumberFor<T, I>>,
{
#[cfg(feature = "try-runtime")]
fn pre_upgrade() -> Result<Vec<u8>, TryRuntimeError> {
if let Some(old_status) = v0::Status::<T, I>::get() {
log::info!("\n Old status - {:?}\n", old_status);
}

let _ = v0::Claimant::<T, I>::iter().for_each(|(key, value)| {
log::info!("\n Old claimant - {:?} -> {:?}\n", key, value);
});

Ok(Default::default())
}

fn on_runtime_upgrade() -> frame_support::weights::Weight {
let mut transactions = 0;

Expand Down Expand Up @@ -122,19 +109,6 @@ pub mod v1 {

T::DbWeight::get().reads_writes(transactions, transactions)
}

#[cfg(feature = "try-runtime")]
fn post_upgrade(_state: Vec<u8>) -> Result<(), TryRuntimeError> {
if let Some(new_status) = crate::Status::<T, I>::get() {
log::info!("\n New status - {:?}\n", new_status);
}

let _ = crate::Claimant::<T, I>::iter().for_each(|(key, value)| {
log::info!("\n New claimant - {:?} -> {:?}\n", key, value);
});

Ok(())
}
}
}

Expand Down

0 comments on commit 5cea0ca

Please sign in to comment.