Skip to content

Commit

Permalink
bugfix: Use DefaultColosseumGenesisBlock for colosseum flag.
Browse files Browse the repository at this point in the history
DefaultGenesisBlock has been modified to return
DefaultColosseumGenesisBlock.
  • Loading branch information
gameofpointers authored and wizeguyy committed Jan 25, 2023
1 parent 7fc5d5e commit ed111c9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cmd/utils/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -1384,7 +1384,7 @@ func SetEthConfig(ctx *cli.Context, stack *node.Node, cfg *ethconfig.Config) {
if !ctx.GlobalIsSet(NetworkIdFlag.Name) {
cfg.NetworkId = 1
}
cfg.Genesis = core.DefaultGenesisBlock()
cfg.Genesis = core.DefaultColosseumGenesisBlock()
SetDNSDiscoveryDefaults(cfg, params.ColosseumGenesisHash)
case ctx.GlobalBool(GardenFlag.Name):
if !ctx.GlobalIsSet(NetworkIdFlag.Name) {
Expand Down Expand Up @@ -1515,7 +1515,7 @@ func MakeGenesis(ctx *cli.Context) *core.Genesis {
var genesis *core.Genesis
switch {
case ctx.GlobalBool(ColosseumFlag.Name):
genesis = core.DefaultGenesisBlock()
genesis = core.DefaultColosseumGenesisBlock()
case ctx.GlobalBool(GardenFlag.Name):
genesis = core.DefaultGardenGenesisBlock()
case ctx.GlobalBool(DeveloperFlag.Name):
Expand Down
8 changes: 7 additions & 1 deletion core/genesis.go
Original file line number Diff line number Diff line change
Expand Up @@ -359,8 +359,14 @@ func GenesisBlockForTesting(db ethdb.Database, addr common.Address, balance *big
return g.MustCommit(db)
}

// DefaultGenesisBlock returns the Quai Colosseum testnet genesis block.
// DefaultGenesisBlock returns the Latest default Genesis block.
// Currently it returns the DefaultColosseumGenesisBlock.
func DefaultGenesisBlock() *Genesis {
return DefaultColosseumGenesisBlock()
}

// DefaultColosseumGenesisBlock returns the Quai Colosseum testnet genesis block.
func DefaultColosseumGenesisBlock() *Genesis {
return &Genesis{
Config: params.ColosseumChainConfig,
Knot: ReadKnot("./core/knot/colosseum_knot.rlp"),
Expand Down

0 comments on commit ed111c9

Please sign in to comment.