Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
klkvr committed Mar 6, 2025
1 parent 000d339 commit 2c877f9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
11 changes: 3 additions & 8 deletions crates/consensus/src/transaction/envelope.rs
Original file line number Diff line number Diff line change
Expand Up @@ -390,15 +390,10 @@ impl TxEnvelope {
/// Recover the signer of the transaction.
#[cfg(feature = "k256")]
pub fn try_into_recovered(
&self,
self,
) -> Result<crate::transaction::Recovered<Self>, alloy_primitives::SignatureError> {
match self {
Self::Legacy(tx) => tx.try_into_recovered(),
Self::Eip2930(tx) => tx.try_into_recovered(),
Self::Eip1559(tx) => tx.try_into_recovered(),
Self::Eip4844(tx) => tx.try_into_recovered(),
Self::Eip7702(tx) => tx.try_into_recovered(),
}
let signer = self.recover_signer()?;
Ok(crate::transaction::Recovered::new_unchecked(self, signer))
}

/// Calculate the signing hash for the transaction.
Expand Down
2 changes: 1 addition & 1 deletion crates/network/src/any/unknowns.rs
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ mod tests {

let tx: AnyRpcTransaction = serde_json::from_str(input).unwrap();

let AnyTxEnvelope::Unknown(inner) = tx.inner.inner.clone() else {
let AnyTxEnvelope::Unknown(inner) = tx.inner.inner.tx().clone() else {
panic!("expected unknown envelope");
};

Expand Down

0 comments on commit 2c877f9

Please sign in to comment.