Force unicode on file loading for guessit

This commit is contained in:
Ruud
2014-10-05 13:53:57 +02:00
parent ab118ea580
commit 984ee7580d

View File

@@ -79,7 +79,9 @@ def file_in_same_dir(ref_file, desired_file):
def load_file_in_same_dir(ref_file, filename):
"""Load a given file. Works even when the file is contained inside a zip."""
path = split_path(ref_file)[:-1] + [filename]
from couchpotato.core.helpers.encoding import toUnicode
path = split_path(toUnicode(ref_file))[:-1] + [filename]
for i, p in enumerate(path):
if p.endswith('.zip'):