switch back to pointers, but this time add etl := etl when iterating over list to set correct pointer

This commit is contained in:
Sam Lewis
2023-01-13 21:57:08 -05:00
parent 18bab6f784
commit 447400868d
2 changed files with 12 additions and 9 deletions

View File

@@ -2,6 +2,7 @@ package gomeassistant
import (
"fmt"
"log"
"time"
"github.com/golang-module/carbon"
@@ -130,7 +131,7 @@ func runSchedules(a *App) {
sched = popSchedule(a)
}
fmt.Println("Next schedule:", sched.nextRunTime)
log.Println("Next schedule:", sched.nextRunTime)
time.Sleep(time.Until(sched.nextRunTime))
sched.maybeRunCallback(a)
requeueSchedule(a, sched)