diff --git a/node_core/src/chain_storage/mod.rs b/node_core/src/chain_storage/mod.rs index 2467a6b..aaeef44 100644 --- a/node_core/src/chain_storage/mod.rs +++ b/node_core/src/chain_storage/mod.rs @@ -242,8 +242,7 @@ impl NodeChainStore { ); info!( - "Snapshot executed at {:?} with results {snapshot_trace:#?}", - block_id + "Snapshot executed at {block_id:?} with results {snapshot_trace:#?}" ); } } diff --git a/sequencer_core/src/lib.rs b/sequencer_core/src/lib.rs index 16b6ae7..301c74c 100644 --- a/sequencer_core/src/lib.rs +++ b/sequencer_core/src/lib.rs @@ -131,23 +131,20 @@ impl SequencerCore { //Tree checks let tx_tree_check = self.store.pub_tx_store.get_tx(*hash).is_some(); - let nullifier_tree_check = nullifier_created_hashes - .iter() - .map(|nullifier_hash| { - self.store.nullifier_store.contains(&UTXONullifier { - utxo_hash: *nullifier_hash, - }) + let nullifier_tree_check = nullifier_created_hashes.iter().any(|nullifier_hash| { + self.store.nullifier_store.contains(&UTXONullifier { + utxo_hash: *nullifier_hash, }) - .any(|check| check); - let utxo_commitments_check = utxo_commitments_created_hashes - .iter() - .map(|utxo_commitment_hash| { - self.store - .utxo_commitments_store - .get_tx(*utxo_commitment_hash) - .is_some() - }) - .any(|check| check); + }); + let utxo_commitments_check = + utxo_commitments_created_hashes + .iter() + .any(|utxo_commitment_hash| { + self.store + .utxo_commitments_store + .get_tx(*utxo_commitment_hash) + .is_some() + }); if tx_tree_check { return Err(TransactionMalformationErrorKind::TxHashAlreadyPresentInTree { tx: *hash });