Change launch logic to receive config in scheduler

This commit is contained in:
2022-12-24 00:10:06 -07:00
parent b29d3a8f80
commit c731e560af
5 changed files with 59 additions and 70 deletions
-14
View File
@@ -1,14 +0,0 @@
package util
import "git.ohea.xyz/cursorius/server/config"
// Generated map for webhook handler config
func CreateWebhookConfig(conf map[string]config.Job) map[string]config.Webhook {
webhookConfig := make(map[string]config.Webhook, 0)
for k, v := range conf {
if v.Webhook != nil {
webhookConfig[k] = *v.Webhook
}
}
return webhookConfig
}