mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-22 12:46:44 +00:00
Ignore nil values in config loop
Skip nil values in configuration processing
This commit is contained in:
parent
243407a3aa
commit
62b27fb6aa
1 changed files with 3 additions and 0 deletions
|
|
@ -103,6 +103,9 @@ func (c *ChainConfig) LoadForks(file []byte) error {
|
|||
epochs["GENESIS"] = 0
|
||||
|
||||
for key, value := range config {
|
||||
if value == nil {
|
||||
continue
|
||||
}
|
||||
if strings.HasSuffix(key, "_FORK_VERSION") {
|
||||
name := key[:len(key)-len("_FORK_VERSION")]
|
||||
switch version := value.(type) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue