Notifications repository + service (#4565)

* Notifications repository

* feat: notifications repo + service

* fix: remove use of notifications/notifications.go

* Update persistence/notificationsrepository/notificationsrepository.go

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix: remove unused method

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Gabe Kangas
2025-11-21 15:34:01 -08:00
committed by GitHub
co-authored by Copilot
parent 96b566664e
commit fea4339e94
9 changed files with 802 additions and 201 deletions
+3 -3
View File
@@ -15,8 +15,8 @@ import (
"github.com/owncast/owncast/core/transcoder"
"github.com/owncast/owncast/core/webhooks"
"github.com/owncast/owncast/models"
"github.com/owncast/owncast/notifications"
"github.com/owncast/owncast/persistence/configrepository"
"github.com/owncast/owncast/services/notifications"
"github.com/owncast/owncast/utils"
)
@@ -189,10 +189,10 @@ func startLiveStreamNotificationsTimer() context.CancelFunc {
}
// Send notification to those who have registered for them.
if notifier, err := notifications.New(data.GetDatastore()); err != nil {
if notificationService, err := notifications.New(data.GetDatastore()); err != nil {
log.Errorln(err)
} else {
notifier.Notify()
notificationService.Notify()
}
now := time.Now()