diff --git a/crates/rpc/rpc/src/debug.rs b/crates/rpc/rpc/src/debug.rs index c3cba02e3e..147c2a9f35 100644 --- a/crates/rpc/rpc/src/debug.rs +++ b/crates/rpc/rpc/src/debug.rs @@ -420,7 +420,9 @@ where &mut db, )?; - if bundles.peek().is_none() && transactions.peek().is_none() { + // If there is more transactions, commit the database + // If there is no transactions, but more bundles, commit to the database too + if transactions.peek().is_some() || bundles.peek().is_some() { db.commit(state); } results.push(trace);