Skip to content

Commit

Permalink
Merge pull request erigontech#133 from testinprod-io/hardfork-time-ni…
Browse files Browse the repository at this point in the history
…l-check

Check if superchain hardfork time is nil
  • Loading branch information
ImTei committed Feb 2, 2024
2 parents ef62ced + 1812270 commit 51367a4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions params/superchain.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ func LoadSuperChainConfig(opStackChainCfg *superchain.ChainConfig) *chain.Config
PragueTime: nil,
BedrockBlock: common.Big0,
RegolithTime: big.NewInt(0),
CanyonTime: new(big.Int).SetUint64(*superchainConfig.Config.CanyonTime),
EcotoneTime: new(big.Int).SetUint64(*superchainConfig.Config.EcotoneTime),
CanyonTime: nil,
EcotoneTime: nil,
TerminalTotalDifficulty: common.Big0,
TerminalTotalDifficultyPassed: true,
Ethash: nil,
Expand All @@ -127,9 +127,11 @@ func LoadSuperChainConfig(opStackChainCfg *superchain.ChainConfig) *chain.Config

if superchainConfig.Config.CanyonTime != nil {
out.ShanghaiTime = new(big.Int).SetUint64(*superchainConfig.Config.CanyonTime) // Shanghai activates with Canyon
out.CanyonTime = new(big.Int).SetUint64(*superchainConfig.Config.CanyonTime)
}
if superchainConfig.Config.EcotoneTime != nil {
out.CancunTime = new(big.Int).SetUint64(*superchainConfig.Config.EcotoneTime) // CancunTime activates with Ecotone
out.EcotoneTime = new(big.Int).SetUint64(*superchainConfig.Config.EcotoneTime)
}

// note: no actual parameters are being loaded, yet.
Expand Down

0 comments on commit 51367a4

Please sign in to comment.