chore: remove block_to_payload_v1 (#14143)

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
This commit is contained in:
Arpit Temani
2025-02-01 16:36:35 +05:30
committed by GitHub
parent 5c7df17a48
commit 209b44829e
11 changed files with 22 additions and 47 deletions

View File

@ -17,7 +17,6 @@ reth-primitives.workspace = true
reth-engine-primitives.workspace = true
reth-payload-primitives.workspace = true
reth-payload-validator.workspace = true
reth-rpc-types-compat.workspace = true
# alloy
alloy-primitives.workspace = true

View File

@ -11,7 +11,6 @@ use alloy_rpc_types_engine::{
use core::convert::Infallible;
use reth_payload_primitives::{BuiltPayload, PayloadBuilderAttributes};
use reth_primitives::{EthPrimitives, SealedBlock};
use reth_rpc_types_compat::engine::payload::block_to_payload_v1;
/// Contains the built payload.
///
@ -118,7 +117,10 @@ impl BuiltPayload for &EthBuiltPayload {
// V1 engine_getPayloadV1 response
impl From<EthBuiltPayload> for ExecutionPayloadV1 {
fn from(value: EthBuiltPayload) -> Self {
block_to_payload_v1(Arc::unwrap_or_clone(value.block))
Self::from_block_unchecked(
value.block().hash(),
&Arc::unwrap_or_clone(value.block).into_block(),
)
}
}