eth: move eth.Config to a common package (#22205)
This moves the eth config definition into a separate package, eth/ethconfig. Packages eth and les can now import this common package instead of importing eth from les, reducing dependencies. Co-authored-by: Felix Lange <fjl@twurst.com>
This commit is contained in:
@ -25,8 +25,8 @@ import (
|
||||
"path/filepath"
|
||||
|
||||
"github.com/ethereum/go-ethereum/core"
|
||||
"github.com/ethereum/go-ethereum/eth"
|
||||
"github.com/ethereum/go-ethereum/eth/downloader"
|
||||
"github.com/ethereum/go-ethereum/eth/ethconfig"
|
||||
"github.com/ethereum/go-ethereum/ethclient"
|
||||
"github.com/ethereum/go-ethereum/ethstats"
|
||||
"github.com/ethereum/go-ethereum/internal/debug"
|
||||
@ -182,7 +182,7 @@ func NewNode(datadir string, config *NodeConfig) (stack *Node, _ error) {
|
||||
}
|
||||
// Register the Ethereum protocol if requested
|
||||
if config.EthereumEnabled {
|
||||
ethConf := eth.DefaultConfig
|
||||
ethConf := ethconfig.Defaults
|
||||
ethConf.Genesis = genesis
|
||||
ethConf.SyncMode = downloader.LightSync
|
||||
ethConf.NetworkId = uint64(config.EthereumNetworkID)
|
||||
|
Reference in New Issue
Block a user