From 4c7c7a692bb53b5ef8db56e39d54d91fec282665 Mon Sep 17 00:00:00 2001 From: panni Date: Wed, 28 Nov 2018 13:34:08 +0100 Subject: [PATCH] subliminal_patch.core: don't assume hints["title"] exists --- libs/subliminal_patch/core.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libs/subliminal_patch/core.py b/libs/subliminal_patch/core.py index 28e3df5ad..3787b9fb3 100644 --- a/libs/subliminal_patch/core.py +++ b/libs/subliminal_patch/core.py @@ -514,7 +514,8 @@ def scan_video(path, dont_use_actual_file=False, hints=None, providers=None, ski # guess hints["single_value"] = True - hints["expected_title"] = [hints["title"]] + if "title" in hints: + hints["expected_title"] = [hints["title"]] guessed_result = guessit(guess_from, options=hints) logger.debug('GuessIt found: %s', json.dumps(guessed_result, cls=GuessitEncoder, indent=4, ensure_ascii=False))