fix incorrect config conditions

This commit is contained in:
Christoph Kluge 2024-10-28 11:56:34 +01:00
parent 01102cb9b0
commit 06f24e988f
2 changed files with 2 additions and 2 deletions

View File

@ -14,7 +14,7 @@ import (
func RegisterUpdateDurationWorker() { func RegisterUpdateDurationWorker() {
var frequency string var frequency string
if config.Keys.CronFrequency.DurationWorker != "" { if config.Keys.CronFrequency != nil && config.Keys.CronFrequency.DurationWorker != "" {
frequency = config.Keys.CronFrequency.DurationWorker frequency = config.Keys.CronFrequency.DurationWorker
} else { } else {
frequency = "5m" frequency = "5m"

View File

@ -20,7 +20,7 @@ import (
func RegisterFootprintWorker() { func RegisterFootprintWorker() {
var frequency string var frequency string
if config.Keys.CronFrequency.FootprintWorker != "" { if config.Keys.CronFrequency != nil && config.Keys.CronFrequency.FootprintWorker != "" {
frequency = config.Keys.CronFrequency.FootprintWorker frequency = config.Keys.CronFrequency.FootprintWorker
} else { } else {
frequency = "10m" frequency = "10m"