1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2024-12-27 01:57:33 +00:00

Small fix for #633.

This commit is contained in:
Louis Vézina 2019-10-29 19:55:53 -04:00
parent 50dfacece0
commit 5a2a5e5e8f

View file

@ -205,11 +205,12 @@ def store_subtitles_movie(file):
database.execute("UPDATE table_movies SET subtitles=? WHERE path=?", database.execute("UPDATE table_movies SET subtitles=? WHERE path=?",
(str(actual_subtitles), path_replace_reverse_movie(file))) (str(actual_subtitles), path_replace_reverse_movie(file)))
movie = database.execute("SELECT radarrId FROM table_movies WHERE path=?", (path_replace_reverse_movie(file),)) movie = database.execute("SELECT radarrId FROM table_movies WHERE path=?",
(path_replace_reverse_movie(file),), only_one=True)
if len(movie): if len(movie):
logging.debug("BAZARR storing those languages to DB: " + str(actual_subtitles)) logging.debug("BAZARR storing those languages to DB: " + str(actual_subtitles))
list_missing_subtitles_movies(no=movie[0]['radarrId']) list_missing_subtitles_movies(no=movie['radarrId'])
else: else:
logging.debug("BAZARR haven't been able to update existing subtitles to DB : " + str(actual_subtitles)) logging.debug("BAZARR haven't been able to update existing subtitles to DB : " + str(actual_subtitles))
else: else: