mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-18 02:40:45 +00:00
Fixed issue Config & consolecmd | File Modified
This commit is contained in:
parent
05a7433768
commit
15e76b17de
2 changed files with 5 additions and 18 deletions
|
|
@ -157,19 +157,6 @@ func makeConfigNode(ctx *cli.Context) (*node.Node, XDCConfig) {
|
||||||
common.IsTestnet = true
|
common.IsTestnet = true
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check rollback hash exist.
|
|
||||||
if rollbackHash := ctx.GlobalString(utils.RollbackFlag.Name); rollbackHash != "" {
|
|
||||||
common.RollbackHash = common.HexToHash(rollbackHash)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Check GasPrice
|
|
||||||
common.MinGasPrice = common.DefaultMinGasPrice
|
|
||||||
if ctx.GlobalIsSet(utils.GasPriceFlag.Name) {
|
|
||||||
if gasPrice := int64(ctx.GlobalInt(utils.GasPriceFlag.Name)); gasPrice > common.DefaultMinGasPrice {
|
|
||||||
common.MinGasPrice = gasPrice
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// read passwords from environment
|
// read passwords from environment
|
||||||
passwords := []string{}
|
passwords := []string{}
|
||||||
for _, env := range cfg.Account.Passwords {
|
for _, env := range cfg.Account.Passwords {
|
||||||
|
|
|
||||||
|
|
@ -77,8 +77,8 @@ JavaScript API. See https://github.com/ethereum/go-ethereum/wiki/JavaScript-Cons
|
||||||
// same time.
|
// same time.
|
||||||
func localConsole(ctx *cli.Context) error {
|
func localConsole(ctx *cli.Context) error {
|
||||||
// Create and start the node based on the CLI flags
|
// Create and start the node based on the CLI flags
|
||||||
node,cfg := makeFullNode(ctx)
|
node, cfg := makeFullNode(ctx)
|
||||||
startNode(ctx, node,cfg)
|
startNode(ctx, node, cfg)
|
||||||
defer node.Stop()
|
defer node.Stop()
|
||||||
|
|
||||||
// Attach to the newly started node and start the JavaScript console
|
// Attach to the newly started node and start the JavaScript console
|
||||||
|
|
@ -179,8 +179,8 @@ func dialRPC(endpoint string) (*rpc.Client, error) {
|
||||||
// everything down.
|
// everything down.
|
||||||
func ephemeralConsole(ctx *cli.Context) error {
|
func ephemeralConsole(ctx *cli.Context) error {
|
||||||
// Create and start the node based on the CLI flags
|
// Create and start the node based on the CLI flags
|
||||||
node,cfg := makeFullNode(ctx)
|
node, cfg := makeFullNode(ctx)
|
||||||
startNode(ctx, node,cfg)
|
startNode(ctx, node, cfg)
|
||||||
defer node.Stop()
|
defer node.Stop()
|
||||||
|
|
||||||
// Attach to the newly started node and start the JavaScript console
|
// Attach to the newly started node and start the JavaScript console
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue