fix(tree): reset cached trie updates on prepend (#6167)

This commit is contained in:
Roman Krasiuk
2024-01-23 08:28:45 +01:00
committed by GitHub
parent 7e982ef3ad
commit c80784f2c7

View File

@@ -76,6 +76,7 @@ impl Chain {
/// Prepends the given state to the current state.
pub fn prepend_state(&mut self, state: BundleState) {
self.state.prepend_state(state);
self.trie_updates.take(); // invalidate cached trie updates
}
/// Return true if chain is empty and has no blocks.