diff options
| author | Leonardo Bishop <me@leonardobishop.com> | 2025-01-20 02:56:25 +0000 |
|---|---|---|
| committer | Leonardo Bishop <me@leonardobishop.com> | 2025-01-20 02:56:25 +0000 |
| commit | dc55f9c0097e1c36b85d7666071b840b902920e9 (patch) | |
| tree | c8c8ae10a9e134810b3361aabc8a9d426d813808 /main.go | |
| parent | 5e7ce6cbae81a1b6e46fe6738dc10039a06bec95 (diff) | |
Add calendar support
Diffstat (limited to 'main.go')
| -rw-r--r-- | main.go | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -7,8 +7,10 @@ import ( "github.com/LMBishop/confplanner/api" config "github.com/LMBishop/confplanner/internal" + "github.com/LMBishop/confplanner/pkg/calendar" "github.com/LMBishop/confplanner/pkg/database" "github.com/LMBishop/confplanner/pkg/favourites" + "github.com/LMBishop/confplanner/pkg/ical" "github.com/LMBishop/confplanner/pkg/schedule" "github.com/LMBishop/confplanner/pkg/user" ) @@ -42,12 +44,16 @@ func run() error { if err != nil { return fmt.Errorf("failed to create schedule service: %w", err) } + calendarService := calendar.NewService(pool) + icalService := ical.NewService(favouritesService, scheduleService) app := api.NewServer(api.ApiServices{ UserService: userService, FavouritesService: favouritesService, ScheduleService: scheduleService, - }) + CalendarService: calendarService, + IcalService: icalService, + }, c.BaseURL) slog.Info("Server is listening", "host", c.Server.Host, "port", c.Server.Port) |
