Skip to content

Commit 5531021

Browse files
committed
Fix clippy
1 parent 3d28a9f commit 5531021

File tree

1 file changed

+1
-5
lines changed
  • crates/anvil/src/eth/backend/mem

1 file changed

+1
-5
lines changed

crates/anvil/src/eth/backend/mem/mod.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2904,11 +2904,7 @@ impl Backend {
29042904
hash: B256,
29052905
opts: GethDebugTracingOptions,
29062906
) -> Option<Result<GethTrace, BlockchainError>> {
2907-
if let Some(tx) = self.blockchain.storage.read().transactions.get(&hash) {
2908-
Some(self.geth_trace(tx, opts))
2909-
} else {
2910-
None
2911-
}
2907+
self.blockchain.storage.read().transactions.get(&hash).map(|tx| self.geth_trace(tx, opts))
29122908
}
29132909

29142910
/// Returns the traces for the given block

0 commit comments

Comments
 (0)