Fix time calculation for TryLater in PeriodicTasks