From 189f0be913333d2610d4d980cca2523aa52ff339 Mon Sep 17 00:00:00 2001 From: remoterami Date: Thu, 1 Aug 2024 10:20:26 +0200 Subject: [PATCH] removed duplicate fields --- backend/pkg/api/types/block.go | 12 ++---------- frontend/types/api/block.ts | 12 ++---------- 2 files changed, 4 insertions(+), 20 deletions(-) diff --git a/backend/pkg/api/types/block.go b/backend/pkg/api/types/block.go index 5b3d071c2..3f3bae56c 100644 --- a/backend/pkg/api/types/block.go +++ b/backend/pkg/api/types/block.go @@ -18,22 +18,13 @@ type BlockSummary struct { type InternalGetBlockResponse ApiDataResponse[BlockSummary] type BlockExecutionPayload struct { - Block uint64 `json:"block"` BlockHash Hash `json:"block_hash"` ParentHash Hash `json:"parent_hash"` PriorityFeesRecipient Address `json:"priority_fees_recipient"` - PriorityFees decimal.Decimal `json:"priority_fees"` GasUsed uint64 `json:"gas_used"` GasLimit uint64 `json:"gas_limit"` BaseFeePerGas decimal.Decimal `json:"base_fee_per_gas"` BaseFees decimal.Decimal `json:"base_fees"` - Transactions struct { - General uint64 `json:"general"` - Blob uint64 `json:"blob"` - } `json:"transactions"` - Time int64 `json:"time"` - ExtraData string `json:"extra_data,omitempty"` - Graffiti string `json:"graffiti"` } type BlockConsensusLayer struct { @@ -49,6 +40,7 @@ type BlockConsensusLayer struct { Deposits uint64 `json:"deposit"` SyncCommittee BlockSyncCommittee `json:"sync_committee"` Eth1Data BlockEth1Data `json:"eth1_data"` + Graffiti string `json:"graffiti"` } type BlockSyncCommittee struct { @@ -114,7 +106,7 @@ type BlockOverview struct { Transactions *struct { General uint64 `json:"general"` Internal uint64 `json:"internal"` - Blob uint64 `json:"blob"` + Blob uint64 `json:"blob,omitempty"` } `json:"transactions,omitempty"` BlockRoot Hash `json:"block_root,omitempty"` ParentRoot Hash `json:"parent_root,omitempty"` diff --git a/frontend/types/api/block.ts b/frontend/types/api/block.ts index d3d5bf74d..56b0ff31b 100644 --- a/frontend/types/api/block.ts +++ b/frontend/types/api/block.ts @@ -19,22 +19,13 @@ export interface BlockSummary { } export type InternalGetBlockResponse = ApiDataResponse; export interface BlockExecutionPayload { - block: number /* uint64 */; block_hash: Hash; parent_hash: Hash; priority_fees_recipient: Address; - priority_fees: string /* decimal.Decimal */; gas_used: number /* uint64 */; gas_limit: number /* uint64 */; base_fee_per_gas: string /* decimal.Decimal */; base_fees: string /* decimal.Decimal */; - transactions: { - general: number /* uint64 */; - blob: number /* uint64 */; - }; - time: number /* int64 */; - extra_data?: string; - graffiti: string; } export interface BlockConsensusLayer { state_root: Hash; @@ -49,6 +40,7 @@ export interface BlockConsensusLayer { deposit: number /* uint64 */; sync_committee: BlockSyncCommittee; eth1_data: BlockEth1Data; + graffiti: string; } export interface BlockSyncCommittee { participation: number /* float64 */; @@ -116,7 +108,7 @@ export interface BlockOverview { transactions?: { general: number /* uint64 */; internal: number /* uint64 */; - blob: number /* uint64 */; + blob?: number /* uint64 */; }; block_root?: Hash; parent_root?: Hash;