mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-01-26 23:58:46 -05:00
feat: add helper for RecoveredBlock::clone_transactions_recovered (#14689)
This commit is contained in:
@@ -291,6 +291,15 @@ impl<B: Block> RecoveredBlock<B> {
|
||||
self.senders.iter().zip(self.block.body().transactions())
|
||||
}
|
||||
|
||||
/// Returns an iterator over cloned `Recovered<Transaction>`
|
||||
#[inline]
|
||||
pub fn clone_transactions_recovered(
|
||||
&self,
|
||||
) -> impl Iterator<Item = Recovered<<B::Body as BlockBody>::Transaction>> + '_ {
|
||||
self.transactions_with_sender()
|
||||
.map(|(sender, tx)| Recovered::new_unchecked(tx.clone(), *sender))
|
||||
}
|
||||
|
||||
/// Returns an iterator over `Recovered<&Transaction>`
|
||||
#[inline]
|
||||
pub fn transactions_recovered(
|
||||
|
||||
Reference in New Issue
Block a user