eth: some typo mistake (#16802) (#948)

This commit is contained in:
JukLee0ira 2025-04-21 16:36:20 +08:00 committed by GitHub
parent e974d96977
commit 63b04b4114
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -364,14 +364,14 @@ func CreateConsensusEngine(stack *node.Node, config *ethash.Config, chainConfig
} }
// Otherwise assume proof-of-work // Otherwise assume proof-of-work
switch { switch config.PowMode {
case config.PowMode == ethash.ModeFake: case ethash.ModeFake:
log.Warn("Ethash used in fake mode") log.Warn("Ethash used in fake mode")
return ethash.NewFaker() return ethash.NewFaker()
case config.PowMode == ethash.ModeTest: case ethash.ModeTest:
log.Warn("Ethash used in test mode") log.Warn("Ethash used in test mode")
return ethash.NewTester() return ethash.NewTester()
case config.PowMode == ethash.ModeShared: case ethash.ModeShared:
log.Warn("Ethash used in shared mode") log.Warn("Ethash used in shared mode")
return ethash.NewShared() return ethash.NewShared()
default: default:
@ -388,7 +388,7 @@ func CreateConsensusEngine(stack *node.Node, config *ethash.Config, chainConfig
} }
} }
// APIs returns the collection of RPC services the ethereum package offers. // APIs return the collection of RPC services the ethereum package offers.
// NOTE, some of these services probably need to be moved to somewhere else. // NOTE, some of these services probably need to be moved to somewhere else.
func (e *Ethereum) APIs() []rpc.API { func (e *Ethereum) APIs() []rpc.API {
apis := ethapi.GetAPIs(e.ApiBackend, e.BlockChain()) apis := ethapi.GetAPIs(e.ApiBackend, e.BlockChain())