Skip to content
This repository has been archived by the owner on Feb 9, 2021. It is now read-only.

Commit

Permalink
[#676] also add getMaxBlockSize
Browse files Browse the repository at this point in the history
  • Loading branch information
redxaxder authored and nc6 committed Feb 3, 2020
1 parent d137117 commit 77975e2
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions cardano-ledger/src/Cardano/Chain/Byron/Auxiliary.hs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ module Cardano.Chain.Byron.Auxiliary (
, getDelegationMap
, getProtocolParams
, getScheduledDelegations
, getMaxBlockSize
-- * Applying blocks
, applyChainTick
, validateBlock
Expand Down Expand Up @@ -122,6 +123,12 @@ getScheduledDelegations =
. D.Iface.schedulingState
. CC.cvsDelegationState

getMaxBlockSize :: CC.ChainValidationState -> Word32
getMaxBlockSize =
fromIntegral
. Update.ppMaxBlockSize
. getProtocolParams

{-------------------------------------------------------------------------------
Update parts of the chain state
-------------------------------------------------------------------------------}
Expand Down

0 comments on commit 77975e2

Please sign in to comment.