mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-19 21:31:37 +00:00
refactor: more logs on countdown
This commit is contained in:
parent
47543e8b1c
commit
37b1929621
1 changed files with 3 additions and 2 deletions
|
|
@ -85,13 +85,14 @@ func (t *CountdownTimer) startTimer(i interface{}, currentRound, highestRound ty
|
|||
}()
|
||||
timer.Reset(t.durationHelper.GetTimeoutDuration(currentRound, highestRound))
|
||||
case info := <-t.resetc:
|
||||
log.Debug("Reset countdown timer")
|
||||
currentRound = info.currentRound
|
||||
highestRound = info.highestRound
|
||||
duration := t.durationHelper.GetTimeoutDuration(currentRound, highestRound)
|
||||
log.Debug("Reset countdown timer", "duration", duration, "currentRound", currentRound, "highestRound", highestRound)
|
||||
if !timer.Stop() {
|
||||
<-timer.C
|
||||
}
|
||||
timer.Reset(t.durationHelper.GetTimeoutDuration(currentRound, highestRound))
|
||||
timer.Reset(duration)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue