From c89ece358f83f68b595a07bd06454f57c99a4f1a Mon Sep 17 00:00:00 2001 From: Rami Khalil Date: Tue, 12 Nov 2024 10:40:55 +0200 Subject: [PATCH] fix(mpt): Remove unnused collapse --- crates/mpt/src/node.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/crates/mpt/src/node.rs b/crates/mpt/src/node.rs index 1ea6ba17c..b441254ac 100644 --- a/crates/mpt/src/node.rs +++ b/crates/mpt/src/node.rs @@ -437,11 +437,10 @@ impl TrieNode { // If the child node is empty, convert the extension into an empty node. *self = Self::Empty; } - Self::Blinded { .. } => { - node.unblind(fetcher)?; - self.collapse_if_possible(fetcher, hinter)?; + _ => { + // If the child is a (blinded?) branch then no need for collapse + // because deletion did not collapse the (blinded?) branch } - _ => {} }, Self::Branch { stack } => { // Count non-empty children