mirror of
https://github.com/Radarr/Radarr.git
synced 2026-04-25 22:37:27 -04:00
New: Movie Added Notification
This commit is contained in:
@@ -19,6 +19,7 @@ namespace NzbDrone.Core.Notifications
|
||||
IHandle<MovieGrabbedEvent>,
|
||||
IHandle<MovieImportedEvent>,
|
||||
IHandle<MoviesDeletedEvent>,
|
||||
IHandle<MovieAddedEvent>,
|
||||
IHandle<MovieFileDeletedEvent>,
|
||||
IHandle<HealthCheckFailedEvent>,
|
||||
IHandle<UpdateInstalledEvent>,
|
||||
@@ -155,6 +156,24 @@ namespace NzbDrone.Core.Notifications
|
||||
}
|
||||
}
|
||||
|
||||
public void Handle(MovieAddedEvent message)
|
||||
{
|
||||
foreach (var notification in _notificationFactory.OnMovieAddedEnabled())
|
||||
{
|
||||
try
|
||||
{
|
||||
if (ShouldHandleMovie(notification.Definition, message.Movie))
|
||||
{
|
||||
notification.OnMovieAdded(message.Movie);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_logger.Warn(ex, "Unable to send OnMovieAdded notification to: " + notification.Definition.Name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Handle(MovieRenamedEvent message)
|
||||
{
|
||||
foreach (var notification in _notificationFactory.OnRenameEnabled())
|
||||
|
||||
Reference in New Issue
Block a user