kill post_finalise (#121)

* kill post_finalise

* update wasm runtimes
This commit is contained in:
Robert Habermeier
2018-04-12 13:17:43 +02:00
committed by Gav Wood
parent 46e3c32e49
commit bdf156d35e
17 changed files with 26 additions and 52 deletions
@@ -104,9 +104,6 @@ impl<
// any final checks
Self::final_checks(&header);
// any stuff that we do after taking the storage root.
Self::post_finalise(&header);
}
/// Finalise the block - it is up the caller to ensure that all header fields are valid
@@ -116,11 +113,7 @@ impl<
// setup extrinsics
<system::Module<System>>::derive_extrinsics();
let header = <system::Module<System>>::finalise();
Self::post_finalise(&header);
header
<system::Module<System>>::finalise()
}
/// Apply outside of the block execution function.
@@ -170,12 +163,6 @@ impl<
header.state_root().check_equal(&storage_root);
assert!(header.state_root() == &storage_root, "Storage root must match that calculated.");
}
fn post_finalise(header: &System::Header) {
// store the header hash in storage; we can't do it before otherwise there would be a
// cyclic dependency.
<system::Module<System>>::record_block_hash(header);
}
}
#[cfg(test)]