Fixed history logging issue for episodes and movies subtitles.

This commit is contained in:
morpheus65535 2023-10-01 14:13:38 -04:00
parent 2467bc0bc0
commit 1f187d89ca
2 changed files with 4 additions and 0 deletions

View File

@ -81,6 +81,8 @@ class EpisodesSubtitles(Resource):
title, 'series', profile_id=get_profile_id(episode_id=sonarrEpisodeId)))
if isinstance(result, list) and len(result):
result = result[0]
if isinstance(result, tuple) and len(result):
result = result[0]
history_log(1, sonarrSeriesId, sonarrEpisodeId, result)
send_notifications(sonarrSeriesId, sonarrEpisodeId, result.message)
store_subtitles(result.path, episodePath)

View File

@ -79,6 +79,8 @@ class MoviesSubtitles(Resource):
sceneName, title, 'movie', profile_id=get_profile_id(movie_id=radarrId)))
if isinstance(result, list) and len(result):
result = result[0]
if isinstance(result, tuple) and len(result):
result = result[0]
history_log_movie(1, radarrId, result)
store_subtitles_movie(result.path, moviePath)
else: