Skip to content

Commit 9e9a4a7

Browse files
qj0r9j0vc2claude
andcommitted
style: fix rustfmt formatting
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent ce97ece commit 9e9a4a7

File tree

2 files changed

+31
-35
lines changed

2 files changed

+31
-35
lines changed

crates/execution/src/engine.rs

Lines changed: 30 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -350,37 +350,36 @@ impl<P: Provider + Clone> ExecutionEngine<P> {
350350
// This prevents NonceTooLow errors when txs from same sender arrive out of order
351351
let mut sorted_txs: Vec<(usize, &Bytes)> = transactions.iter().enumerate().collect();
352352
sorted_txs.sort_by(|(_, a), (_, b)| {
353-
let parse_tx =
354-
|tx_bytes: &Bytes| -> Option<(alloy_primitives::Address, u64)> {
355-
let tx_envelope = TxEnvelope::decode_2718(&mut tx_bytes.as_ref()).ok()?;
356-
let nonce = tx_envelope.nonce();
357-
358-
// Recover sender from signature
359-
let sender = match &tx_envelope {
360-
TxEnvelope::Legacy(signed) => signed
361-
.signature()
362-
.recover_address_from_prehash(&signed.signature_hash())
363-
.ok(),
364-
TxEnvelope::Eip2930(signed) => signed
365-
.signature()
366-
.recover_address_from_prehash(&signed.signature_hash())
367-
.ok(),
368-
TxEnvelope::Eip1559(signed) => signed
369-
.signature()
370-
.recover_address_from_prehash(&signed.signature_hash())
371-
.ok(),
372-
TxEnvelope::Eip4844(signed) => signed
373-
.signature()
374-
.recover_address_from_prehash(&signed.signature_hash())
375-
.ok(),
376-
TxEnvelope::Eip7702(signed) => signed
377-
.signature()
378-
.recover_address_from_prehash(&signed.signature_hash())
379-
.ok(),
380-
}?;
381-
382-
Some((sender, nonce))
383-
};
353+
let parse_tx = |tx_bytes: &Bytes| -> Option<(alloy_primitives::Address, u64)> {
354+
let tx_envelope = TxEnvelope::decode_2718(&mut tx_bytes.as_ref()).ok()?;
355+
let nonce = tx_envelope.nonce();
356+
357+
// Recover sender from signature
358+
let sender = match &tx_envelope {
359+
TxEnvelope::Legacy(signed) => signed
360+
.signature()
361+
.recover_address_from_prehash(&signed.signature_hash())
362+
.ok(),
363+
TxEnvelope::Eip2930(signed) => signed
364+
.signature()
365+
.recover_address_from_prehash(&signed.signature_hash())
366+
.ok(),
367+
TxEnvelope::Eip1559(signed) => signed
368+
.signature()
369+
.recover_address_from_prehash(&signed.signature_hash())
370+
.ok(),
371+
TxEnvelope::Eip4844(signed) => signed
372+
.signature()
373+
.recover_address_from_prehash(&signed.signature_hash())
374+
.ok(),
375+
TxEnvelope::Eip7702(signed) => signed
376+
.signature()
377+
.recover_address_from_prehash(&signed.signature_hash())
378+
.ok(),
379+
}?;
380+
381+
Some((sender, nonce))
382+
};
384383

385384
match (parse_tx(a), parse_tx(b)) {
386385
(Some((sender_a, nonce_a)), Some((sender_b, nonce_b))) => {

crates/rpc/src/adapters.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1563,10 +1563,7 @@ impl ChannelMempoolApi {
15631563
}
15641564

15651565
if retried > 0 {
1566-
info!(
1567-
"Retried {} pending transactions for re-processing",
1568-
retried
1569-
);
1566+
info!("Retried {} pending transactions for re-processing", retried);
15701567
}
15711568

15721569
retried

0 commit comments

Comments
 (0)