From c44d7f20bc96e5143d603e198564b3999224a774 Mon Sep 17 00:00:00 2001 From: James Tombleson Date: Wed, 1 May 2024 18:27:03 -0700 Subject: [PATCH] server passes in the db to cron now --- cmd/server.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/server.go b/cmd/server.go index c028d1d..15ade00 100644 --- a/cmd/server.go +++ b/cmd/server.go @@ -11,7 +11,7 @@ import ( "git.jamestombleson.com/jtom38/newsbot-api/docs" "git.jamestombleson.com/jtom38/newsbot-api/internal/database" - "git.jamestombleson.com/jtom38/newsbot-api/internal/handler/v1" + v1 "git.jamestombleson.com/jtom38/newsbot-api/internal/handler/v1" "git.jamestombleson.com/jtom38/newsbot-api/internal/services" "git.jamestombleson.com/jtom38/newsbot-api/internal/services/cron" ) @@ -44,7 +44,7 @@ func main() { queries := database.New(db) - c := cron.NewScheduler(ctx) + c := cron.NewScheduler(ctx, db) c.Start() server := v1.NewServer(ctx, queries, configs, db)