mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-01-26 15:48:13 -05:00
Implement ExecutionPayload for OpExecutionData (#14682)
This commit is contained in:
@@ -126,3 +126,30 @@ where
|
||||
Self::PayloadAttributes(attributes)
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "op")]
|
||||
impl ExecutionPayload for op_alloy_rpc_types_engine::OpExecutionData {
|
||||
fn parent_hash(&self) -> B256 {
|
||||
self.parent_hash()
|
||||
}
|
||||
|
||||
fn block_hash(&self) -> B256 {
|
||||
self.block_hash()
|
||||
}
|
||||
|
||||
fn block_number(&self) -> u64 {
|
||||
self.block_number()
|
||||
}
|
||||
|
||||
fn withdrawals(&self) -> Option<&Vec<Withdrawal>> {
|
||||
Some(&self.payload.as_v2().withdrawals)
|
||||
}
|
||||
|
||||
fn parent_beacon_block_root(&self) -> Option<B256> {
|
||||
self.sidecar.parent_beacon_block_root()
|
||||
}
|
||||
|
||||
fn timestamp(&self) -> u64 {
|
||||
self.payload.as_v2().timestamp()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user