Skip to content

Commit

Permalink
feat: From impl for variant (#1488)
Browse files Browse the repository at this point in the history
  • Loading branch information
prestwich authored Oct 16, 2024
1 parent 0787281 commit 881d15c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions crates/consensus/src/transaction/eip4844.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,15 @@ impl From<(TxEip4844, BlobTransactionSidecar)> for TxEip4844Variant {
}
}

impl From<TxEip4844Variant> for TxEip4844 {
fn from(tx: TxEip4844Variant) -> Self {
match tx {
TxEip4844Variant::TxEip4844(tx) => tx,
TxEip4844Variant::TxEip4844WithSidecar(tx) => tx.tx,
}
}
}

impl TxEip4844Variant {
/// Verifies that the transaction's blob data, commitments, and proofs are all valid.
///
Expand Down

0 comments on commit 881d15c

Please sign in to comment.