From ce9977ff29de582cf0f06e3ac37bca86f0f247fb Mon Sep 17 00:00:00 2001 From: Peter Zhang Date: Mon, 7 Jul 2025 23:10:25 +0800 Subject: [PATCH] fix issue --- node/storage/src/log_store/log_manager.rs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/node/storage/src/log_store/log_manager.rs b/node/storage/src/log_store/log_manager.rs index f873076..1b9cc77 100644 --- a/node/storage/src/log_store/log_manager.rs +++ b/node/storage/src/log_store/log_manager.rs @@ -316,9 +316,8 @@ impl LogStoreWrite for LogManager { .tx_store .get_tx_seq_list_by_data_root(&tx.data_merkle_root)?; // Check if there are other same-root transaction not finalized. - if same_root_seq_list.first() == Some(&tx_seq) { - self.copy_tx_and_finalize(tx_seq, same_root_seq_list)?; - } + self.copy_tx_and_finalize(tx_seq, same_root_seq_list)?; + self.tx_store.finalize_tx(tx_seq)?; Ok(()) } else { @@ -353,9 +352,8 @@ impl LogStoreWrite for LogManager { .tx_store .get_tx_seq_list_by_data_root(&tx.data_merkle_root)?; // Check if there are other same-root transaction not finalized. - if same_root_seq_list.first() == Some(&tx_seq) { - self.copy_tx_and_finalize(tx_seq, same_root_seq_list)?; - } + self.copy_tx_and_finalize(tx_seq, same_root_seq_list)?; + metrics::FINALIZE_TX_WITH_HASH.update_since(start_time); Ok(true) } else {