Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Add a weight for StorageVersion write
Browse files Browse the repository at this point in the history
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
  • Loading branch information
slumber and bkchr committed Sep 17, 2021
1 parent 107c3d0 commit 7885576
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pallets/parachain-system/src/migration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pub fn on_runtime_upgrade<T: Config>() -> Weight {
let mut weight: Weight = 0;

if StorageVersion::get::<Pallet<T>>() == 0 {
weight = weight.saturating_add(v1::migrate::<T>());
weight = weight.saturating_add(v1::migrate::<T>()).saturating_add(T::DbWeight::get().writes(1));
StorageVersion::new(1).put::<Pallet<T>>();
}

Expand Down

0 comments on commit 7885576

Please sign in to comment.