0.2.64 update
This commit is contained in:
@@ -103,11 +103,20 @@ func (s *Server) handleServiceStatus(w http.ResponseWriter, r *http.Request, ses
|
||||
// Nothing to celebrate while the service is down, and the client is showing the
|
||||
// maintenance screen anyway.
|
||||
if !state.Enabled {
|
||||
if found := mergeAlerts(
|
||||
s.publishedAlerts(r.Context()),
|
||||
s.sonarrAiredAlerts(r.Context()),
|
||||
); len(found) > 0 {
|
||||
alerts = found
|
||||
published, sonarr := s.publishedAlerts(r.Context()), s.sonarrAiredAlerts(r.Context())
|
||||
if len(published) > 0 || len(sonarr) > 0 {
|
||||
prefs, err := s.notificationPreferencesFor(r.Context(), sess.EmbyUserID)
|
||||
if err != nil {
|
||||
s.loggerFor(r.Context()).Warn("notification preferences unavailable", "error", err)
|
||||
alerts = mergeAlerts(published, sonarr)
|
||||
} else {
|
||||
// Filter before trimming so three muted Sonarr stories cannot crowd a
|
||||
// permitted Radarr or service notice out of the small client queue.
|
||||
alerts = mergeAlerts(
|
||||
filterClientAlerts(published, prefs),
|
||||
filterClientAlerts(sonarr, prefs),
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
compatible, compatibilityMessage := compatibilityFor(r)
|
||||
|
||||
Reference in New Issue
Block a user