summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--bazarr/get_subtitle.py9
-rw-r--r--bazarr/utils.py1
2 files changed, 9 insertions, 1 deletions
diff --git a/bazarr/get_subtitle.py b/bazarr/get_subtitle.py
index 02956ad17..9bf0875f9 100644
--- a/bazarr/get_subtitle.py
+++ b/bazarr/get_subtitle.py
@@ -271,7 +271,9 @@ def download_subtitle(path, language, audio_language, hi, forced, providers, pro
reversed_path = path_mappings.path_replace_reverse(path)
reversed_subtitles_path = path_mappings.path_replace_reverse(downloaded_path)
notify_sonarr(episode_metadata['sonarrSeriesId'])
- event_stream(type='episode-wanted', action='delete', payload=episode_metadata['sonarrEpisodeId'])
+ event_stream(type='series', action='update', payload=episode_metadata['sonarrSeriesId'])
+ event_stream(type='episode-wanted', action='delete',
+ payload=episode_metadata['sonarrEpisodeId'])
else:
reversed_path = path_mappings.path_replace_reverse_movie(path)
@@ -717,10 +719,14 @@ def manual_upload_subtitle(path, language, forced, hi, title, scene_name, media_
reversed_path = path_mappings.path_replace_reverse(path)
reversed_subtitles_path = path_mappings.path_replace_reverse(subtitle_path)
notify_sonarr(episode_metadata['sonarrSeriesId'])
+ event_stream(type='series', action='update', payload=episode_metadata['sonarrSeriesId'])
+ event_stream(type='episode-wanted', action='delete', payload=episode_metadata['sonarrEpisodeId'])
else:
reversed_path = path_mappings.path_replace_reverse_movie(path)
reversed_subtitles_path = path_mappings.path_replace_reverse_movie(subtitle_path)
notify_radarr(movie_metadata['radarrId'])
+ event_stream(type='movie', action='update', payload=movie_metadata['radarrId'])
+ event_stream(type='movie-wanted', action='delete', payload=movie_metadata['radarrId'])
return message, reversed_path, reversed_subtitles_path
@@ -1066,6 +1072,7 @@ def wanted_download_subtitles(sonarr_episode_id):
store_subtitles(episode['path'], path_mappings.path_replace(episode['path']))
history_log(1, episode['sonarrSeriesId'], episode['sonarrEpisodeId'], message, path,
language_code, provider, score, subs_id, subs_path)
+ event_stream(type='series', action='update', payload=episode['sonarrSeriesId'])
event_stream(type='episode-wanted', action='delete', payload=episode['sonarrEpisodeId'])
send_notifications(episode['sonarrSeriesId'], episode['sonarrEpisodeId'], message)
else:
diff --git a/bazarr/utils.py b/bazarr/utils.py
index a0f68bcff..3b739aca7 100644
--- a/bazarr/utils.py
+++ b/bazarr/utils.py
@@ -384,6 +384,7 @@ def delete_subtitles(media_type, language, forced, hi, media_path, subtitles_pat
subtitles_path=path_mappings.path_replace_reverse(subtitles_path))
store_subtitles(path_mappings.path_replace_reverse(media_path), media_path)
notify_sonarr(sonarr_series_id)
+ event_stream(type='series', action='update', payload=sonarr_series_id)
event_stream(type='episode-wanted', action='update', payload=sonarr_episode_id)
return True
else: