Skip to content

Commit

Permalink
added the cronjob as a cronjob
Browse files Browse the repository at this point in the history
  • Loading branch information
CommanderStorm committed Feb 7, 2024
1 parent 9270fa0 commit f50ed82
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions server/backend/cron/cronjobs.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ const (
NewExamResultsHook = "newExamResultsHook"
MovieType = "movie"
FeedbackEmail = "feedbackEmail"
AlarmType = "alarm"

/* MensaType = "mensa"
AlarmType = "alarm" */
// MensaType = "mensa"
)

func New(db *gorm.DB) *CronService {
Expand Down Expand Up @@ -66,6 +66,7 @@ func (c *CronService) Run() error {
NewExamResultsHook,
MovieType,
FeedbackEmail,
AlarmType,
).
Scan(&res)

Expand Down Expand Up @@ -111,6 +112,8 @@ func (c *CronService) Run() error {
g.Go(func() error { return c.iosActivityReset() })
case FeedbackEmail:
g.Go(func() error { return c.feedbackEmailCron() })
case AlarmType:
g.Go(func() error { return c.alarmCron() })
}
}

Expand Down

0 comments on commit f50ed82

Please sign in to comment.