(storedcfg *configs.ChainConfig, newcfg *configs.ChainConfig, db database.Database, stored common.Hash)
| 180 | } |
| 181 | |
| 182 | func updateChainConfig(storedcfg *configs.ChainConfig, newcfg *configs.ChainConfig, db database.Database, stored common.Hash) *configs.ChainConfig { |
| 183 | if storedcfg == nil { |
| 184 | log.Warn("Found genesis block without chain config") |
| 185 | } |
| 186 | // NOTICE: in future we may need to check the compatibility of old and new configurations. |
| 187 | rawdb.WriteChainConfig(db, stored, newcfg) |
| 188 | return newcfg |
| 189 | } |
| 190 | |
| 191 | // OpenGenesisBlock opens genesis block and returns its chain configuration and hash. |
| 192 | // Return errors when genesis block not exist or genesis block configuration not exist. |
no test coverage detected