From cc3628a19f92112e1493e0f6adbfbd876a3de816 Mon Sep 17 00:00:00 2001 From: morpheus65535 Date: Sat, 1 May 2021 00:04:10 -0400 Subject: [PATCH] Fix for automatic subsync history logging --- bazarr/get_subtitle.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/bazarr/get_subtitle.py b/bazarr/get_subtitle.py index 285981d3e..6579e07e2 100644 --- a/bazarr/get_subtitle.py +++ b/bazarr/get_subtitle.py @@ -258,7 +258,7 @@ def download_subtitle(path, language, audio_language, hi, forced, providers, pro series_id = episode_metadata['sonarrSeriesId'] episode_id = episode_metadata['sonarrEpisodeId'] sync_subtitles(video_path=path, srt_path=downloaded_path, - srt_lang=downloaded_language_code3, media_type=media_type, + srt_lang=downloaded_language_code2, media_type=media_type, percent_score=percent_score, sonarr_series_id=episode_metadata['sonarrSeriesId'], sonarr_episode_id=episode_metadata['sonarrEpisodeId']) @@ -269,7 +269,7 @@ def download_subtitle(path, language, audio_language, hi, forced, providers, pro series_id = "" episode_id = movie_metadata['radarrId'] sync_subtitles(video_path=path, srt_path=downloaded_path, - srt_lang=downloaded_language_code3, media_type=media_type, + srt_lang=downloaded_language_code2, media_type=media_type, percent_score=percent_score, radarr_id=movie_metadata['radarrId']) @@ -583,7 +583,7 @@ def manual_download_subtitle(path, language, audio_language, hi, forced, subtitl series_id = episode_metadata['sonarrSeriesId'] episode_id = episode_metadata['sonarrEpisodeId'] sync_subtitles(video_path=path, srt_path=downloaded_path, - srt_lang=downloaded_language_code3, media_type=media_type, + srt_lang=downloaded_language_code2, media_type=media_type, percent_score=score, sonarr_series_id=episode_metadata['sonarrSeriesId'], sonarr_episode_id=episode_metadata['sonarrEpisodeId']) @@ -594,7 +594,7 @@ def manual_download_subtitle(path, language, audio_language, hi, forced, subtitl series_id = "" episode_id = movie_metadata['radarrId'] sync_subtitles(video_path=path, srt_path=downloaded_path, - srt_lang=downloaded_language_code3, media_type=media_type, + srt_lang=downloaded_language_code2, media_type=media_type, percent_score=score, radarr_id=movie_metadata['radarrId']) if use_postprocessing: @@ -711,7 +711,7 @@ def manual_upload_subtitle(path, language, forced, title, scene_name, media_type only_one=True) series_id = episode_metadata['sonarrSeriesId'] episode_id = episode_metadata['sonarrEpisodeId'] - sync_subtitles(video_path=path, srt_path=subtitle_path, srt_lang=uploaded_language_code3, media_type=media_type, + sync_subtitles(video_path=path, srt_path=subtitle_path, srt_lang=uploaded_language_code2, media_type=media_type, percent_score=100, sonarr_series_id=episode_metadata['sonarrSeriesId'], sonarr_episode_id=episode_metadata['sonarrEpisodeId']) else: @@ -720,7 +720,7 @@ def manual_upload_subtitle(path, language, forced, title, scene_name, media_type only_one=True) series_id = "" episode_id = movie_metadata['radarrId'] - sync_subtitles(video_path=path, srt_path=subtitle_path, srt_lang=uploaded_language_code3, media_type=media_type, + sync_subtitles(video_path=path, srt_path=subtitle_path, srt_lang=uploaded_language_code2, media_type=media_type, percent_score=100, radarr_id=movie_metadata['radarrId']) if use_postprocessing: