Skip to content

Commit

Permalink
fix: only set blob versioned hashes for 4844 (paradigmxyz#7354)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsse authored and Ruteri committed Apr 17, 2024
1 parent bdd19d5 commit 5f11c65
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions crates/rpc/rpc-types-compat/src/transaction/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ fn fill(

// let chain_id = signed_tx.chain_id().map(U64::from);
let chain_id = signed_tx.chain_id();
let mut blob_versioned_hashes = Vec::new();
let mut blob_versioned_hashes = None;

#[allow(unreachable_patterns)]
let access_list = match &mut signed_tx.transaction {
Expand All @@ -104,7 +104,7 @@ fn fill(
)),
PrimitiveTransaction::Eip4844(tx) => {
// extract the blob hashes from the transaction
blob_versioned_hashes = std::mem::take(&mut tx.blob_versioned_hashes);
blob_versioned_hashes = Some(std::mem::take(&mut tx.blob_versioned_hashes));

Some(AccessList(
tx.access_list
Expand Down Expand Up @@ -148,7 +148,7 @@ fn fill(
transaction_index,
// EIP-4844 fields
max_fee_per_blob_gas: signed_tx.max_fee_per_blob_gas().map(U256::from),
blob_versioned_hashes: Some(blob_versioned_hashes),
blob_versioned_hashes,
// Optimism fields
#[cfg(feature = "optimism")]
other: OptimismTransactionFields {
Expand Down

0 comments on commit 5f11c65

Please sign in to comment.