fix: initial value of lastTimeExecuted

This commit is contained in:
Richard Ramos 2022-12-08 15:48:16 -04:00
parent 62e1f59d4f
commit b929aeeb4e
No known key found for this signature in database
GPG Key ID: BD36D48BC9FFC88C
1 changed files with 2 additions and 1 deletions

View File

@ -24,7 +24,8 @@ func (w *WakuNode) startKeepAlive(t time.Duration) {
ticker := time.NewTicker(t)
defer ticker.Stop()
lastTimeExecuted := <-ticker.C
lastTimeExecuted := time.Now()
sleepDetectionInterval := int64(t) * 3
for {