Skip to content

Commit 78a20bd

Browse files
Fix block struct according to the spec
* `totalDifficulty` field removed as it was removed from the eth spec in ethereum/execution-apis#570 * `difficulty` field is not required, making it optional
1 parent 8873ba6 commit 78a20bd

File tree

1 file changed

+1
-3
lines changed
  • packages/ethereum/src/Network/Ethereum/Api

1 file changed

+1
-3
lines changed

packages/ethereum/src/Network/Ethereum/Api/Types.hs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -277,10 +277,8 @@ data BlockT tx = Block
277277
-- ^ DATA, 32 Bytes - the root of the receipts trie of the block.
278278
, blockMiner :: !Address
279279
-- ^ DATA, 20 Bytes - the address of the beneficiary to whom the mining rewards were given.
280-
, blockDifficulty :: !Quantity
280+
, blockDifficulty :: !(Maybe Quantity)
281281
-- ^ QUANTITY - integer of the difficulty for this block.
282-
, blockTotalDifficulty :: !(Maybe Quantity)
283-
-- ^ QUANTITY - integer of the total difficulty of the chain until this block.
284282
, blockExtraData :: !HexString
285283
-- ^ DATA - the "extra data" field of this block.
286284
, blockSize :: !Quantity

0 commit comments

Comments
 (0)