diff --git a/internal/taskManager/updateDurationService.go b/internal/taskManager/updateDurationService.go index fc7f446..81d799e 100644 --- a/internal/taskManager/updateDurationService.go +++ b/internal/taskManager/updateDurationService.go @@ -14,7 +14,7 @@ import ( func RegisterUpdateDurationWorker() { var frequency string - if config.Keys.CronFrequency.DurationWorker != "" { + if config.Keys.CronFrequency != nil && config.Keys.CronFrequency.DurationWorker != "" { frequency = config.Keys.CronFrequency.DurationWorker } else { frequency = "5m" diff --git a/internal/taskManager/updateFootprintService.go b/internal/taskManager/updateFootprintService.go index a0eccc8..efca6d1 100644 --- a/internal/taskManager/updateFootprintService.go +++ b/internal/taskManager/updateFootprintService.go @@ -20,7 +20,7 @@ import ( func RegisterFootprintWorker() { var frequency string - if config.Keys.CronFrequency.FootprintWorker != "" { + if config.Keys.CronFrequency != nil && config.Keys.CronFrequency.FootprintWorker != "" { frequency = config.Keys.CronFrequency.FootprintWorker } else { frequency = "10m"