diff --git a/eth/api_backend.go b/eth/api_backend.go index fde05584cb..81b70a8573 100644 --- a/eth/api_backend.go +++ b/eth/api_backend.go @@ -77,6 +77,9 @@ func (b *EthAPIBackend) HeaderByNumber(ctx context.Context, number rpc.BlockNumb return b.eth.blockchain.CurrentBlock().Header(), nil } if number == rpc.FinalizedBlockNumber { + if !b.eth.config.EnableRollupVerify { + return nil, errors.New("sync L1 finalized batch feature not enabled, cannot query L2 finalized block height") + } finalizedBlockHeightPtr := rawdb.ReadFinalizedL2BlockNumber(b.eth.ChainDb()) if finalizedBlockHeightPtr == nil { return nil, errors.New("L2 finalized block height not found in database") @@ -119,6 +122,9 @@ func (b *EthAPIBackend) BlockByNumber(ctx context.Context, number rpc.BlockNumbe return b.eth.blockchain.CurrentBlock(), nil } if number == rpc.FinalizedBlockNumber { + if !b.eth.config.EnableRollupVerify { + return nil, errors.New("sync L1 finalized batch feature not enabled, cannot query L2 finalized block height") + } finalizedBlockHeightPtr := rawdb.ReadFinalizedL2BlockNumber(b.eth.ChainDb()) if finalizedBlockHeightPtr == nil { return nil, errors.New("L2 finalized block height not found in database") diff --git a/params/version.go b/params/version.go index 807e341306..fe018b48a4 100644 --- a/params/version.go +++ b/params/version.go @@ -24,7 +24,7 @@ import ( const ( VersionMajor = 5 // Major version component of the current release VersionMinor = 3 // Minor version component of the current release - VersionPatch = 5 // Patch version component of the current release + VersionPatch = 6 // Patch version component of the current release VersionMeta = "mainnet" // Version metadata to append to the version string )