mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-14 03:56:36 +00:00
cmd/utils: fix witness stats auto-enable to respect config file (#34729)
Auto-enable logic for `StatelessSelfValidation` was reading CLI flag directly via `ctx.Bool()`, bypassing the merged `cfg.EnableWitnessStats` value. Now uses `cfg.EnableWitnessStats` so config file settings trigger the same auto-enable behavior as CLI flags.
This commit is contained in:
parent
ef0f1f96f9
commit
0b35ad95f5
1 changed files with 1 additions and 1 deletions
|
|
@ -1899,7 +1899,7 @@ func SetEthConfig(ctx *cli.Context, stack *node.Node, cfg *ethconfig.Config) {
|
||||||
cfg.StatelessSelfValidation = ctx.Bool(VMStatelessSelfValidationFlag.Name)
|
cfg.StatelessSelfValidation = ctx.Bool(VMStatelessSelfValidationFlag.Name)
|
||||||
}
|
}
|
||||||
// Auto-enable StatelessSelfValidation when witness stats are enabled
|
// Auto-enable StatelessSelfValidation when witness stats are enabled
|
||||||
if ctx.Bool(VMWitnessStatsFlag.Name) {
|
if cfg.EnableWitnessStats {
|
||||||
cfg.StatelessSelfValidation = true
|
cfg.StatelessSelfValidation = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue