1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-24 22:35:49 -04:00

New: On Health Restored notification

(cherry picked from commit 5fdc8514da7c7ad98192f2ecb2415b3a7b5d0d05)
This commit is contained in:
The Dark
2023-05-08 02:57:14 +01:00
committed by Bogdan
parent 164f9ca868
commit 8563ed0a20
37 changed files with 286 additions and 4 deletions
@@ -17,6 +17,7 @@ namespace NzbDrone.Core.Notifications
List<INotification> OnMovieDeleteEnabled();
List<INotification> OnMovieFileDeleteEnabled();
List<INotification> OnHealthIssueEnabled();
List<INotification> OnHealthRestoredEnabled();
List<INotification> OnApplicationUpdateEnabled();
}
@@ -72,6 +73,11 @@ namespace NzbDrone.Core.Notifications
return GetAvailableProviders().Where(n => ((NotificationDefinition)n.Definition).OnHealthIssue).ToList();
}
public List<INotification> OnHealthRestoredEnabled()
{
return GetAvailableProviders().Where(n => ((NotificationDefinition)n.Definition).OnHealthRestored).ToList();
}
public List<INotification> OnApplicationUpdateEnabled()
{
return GetAvailableProviders().Where(n => ((NotificationDefinition)n.Definition).OnApplicationUpdate).ToList();
@@ -90,6 +96,7 @@ namespace NzbDrone.Core.Notifications
definition.SupportsOnMovieFileDelete = provider.SupportsOnMovieFileDelete;
definition.SupportsOnMovieFileDeleteForUpgrade = provider.SupportsOnMovieFileDeleteForUpgrade;
definition.SupportsOnHealthIssue = provider.SupportsOnHealthIssue;
definition.SupportsOnHealthRestored = provider.SupportsOnHealthRestored;
definition.SupportsOnApplicationUpdate = provider.SupportsOnApplicationUpdate;
}
}