diff --git a/params/config.go b/params/config.go index 439e882189..4c445982c0 100644 --- a/params/config.go +++ b/params/config.go @@ -375,6 +375,9 @@ type EthashConfig struct{} // String implements the stringer interface, returning the consensus engine details. func (c *EthashConfig) String() string { + if c == nil { + return "" + } return "ethash" } @@ -386,7 +389,10 @@ type CliqueConfig struct { // String implements the stringer interface, returning the consensus engine details. func (c *CliqueConfig) String() string { - return "clique" + if c == nil { + return "" + } + return fmt.Sprintf("Clique { Period: %d, Epoch: %d }", c.Period, c.Epoch) } // Description returns a human-readable description of ChainConfig.