mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
eth: inline the function
This commit is contained in:
parent
bcd5792ca4
commit
b98b30bcb8
1 changed files with 1 additions and 6 deletions
|
|
@ -179,13 +179,8 @@ func newHandler(config *handlerConfig) (*handler, error) {
|
||||||
log.Info("Enabled snap sync", "head", head.Number, "hash", head.Hash())
|
log.Info("Enabled snap sync", "head", head.Number, "hash", head.Hash())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// If the sync succeeds, mark the local node as synced and enable all features
|
|
||||||
// with state synchronization requirements.
|
|
||||||
success := func() {
|
|
||||||
h.enableSyncedFeatures()
|
|
||||||
}
|
|
||||||
// Construct the downloader (long sync)
|
// Construct the downloader (long sync)
|
||||||
h.downloader = downloader.New(config.Database, h.eventMux, h.chain, nil, h.removePeer, success)
|
h.downloader = downloader.New(config.Database, h.eventMux, h.chain, nil, h.removePeer, h.enableSyncedFeatures)
|
||||||
if ttd := h.chain.Config().TerminalTotalDifficulty; ttd != nil {
|
if ttd := h.chain.Config().TerminalTotalDifficulty; ttd != nil {
|
||||||
if h.chain.Config().TerminalTotalDifficultyPassed {
|
if h.chain.Config().TerminalTotalDifficultyPassed {
|
||||||
log.Info("Chain post-merge, sync via beacon client")
|
log.Info("Chain post-merge, sync via beacon client")
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue