mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 19:09:54 +00:00
chore: remove clippy::manual_unwarp_or_default (#10146)
This commit is contained in:
@ -389,27 +389,26 @@ pub trait EthTransactions: LoadTransaction {
|
||||
) => {
|
||||
// As per the EIP, we follow the same semantics as EIP-1559.
|
||||
Some(TypedTransactionRequest::EIP4844(EIP4844TransactionRequest {
|
||||
chain_id: 0,
|
||||
nonce: nonce.unwrap_or_default(),
|
||||
max_priority_fee_per_gas: U256::from(
|
||||
max_priority_fee_per_gas.unwrap_or_default(),
|
||||
),
|
||||
max_fee_per_gas: U256::from(max_fee_per_gas.unwrap_or_default()),
|
||||
gas_limit: U256::from(gas.unwrap_or_default()),
|
||||
value: value.unwrap_or_default(),
|
||||
input: data.into_input().unwrap_or_default(),
|
||||
#[allow(clippy::manual_unwrap_or_default)] // clippy is suggesting here unwrap_or_default
|
||||
to: match to {
|
||||
Some(TxKind::Call(to)) => to,
|
||||
_ => Address::default(),
|
||||
},
|
||||
access_list: access_list.unwrap_or_default(),
|
||||
chain_id: 0,
|
||||
nonce: nonce.unwrap_or_default(),
|
||||
max_priority_fee_per_gas: U256::from(
|
||||
max_priority_fee_per_gas.unwrap_or_default(),
|
||||
),
|
||||
max_fee_per_gas: U256::from(max_fee_per_gas.unwrap_or_default()),
|
||||
gas_limit: U256::from(gas.unwrap_or_default()),
|
||||
value: value.unwrap_or_default(),
|
||||
input: data.into_input().unwrap_or_default(),
|
||||
to: match to {
|
||||
Some(TxKind::Call(to)) => to,
|
||||
_ => Address::default(),
|
||||
},
|
||||
access_list: access_list.unwrap_or_default(),
|
||||
|
||||
// eip-4844 specific.
|
||||
max_fee_per_blob_gas: U256::from(max_fee_per_blob_gas),
|
||||
blob_versioned_hashes,
|
||||
sidecar,
|
||||
}))
|
||||
// eip-4844 specific.
|
||||
max_fee_per_blob_gas: U256::from(max_fee_per_blob_gas),
|
||||
blob_versioned_hashes,
|
||||
sidecar,
|
||||
}))
|
||||
}
|
||||
|
||||
_ => None,
|
||||
|
||||
Reference in New Issue
Block a user