1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2025-01-31 11:22:38 +00:00

Incresing the number of line used for language detection in subtitles

This commit is contained in:
morpheus65535 2018-01-24 14:38:00 -05:00
parent eb2dcbb283
commit 6134d88f7f

View file

@ -36,7 +36,7 @@ def store_subtitles(file):
actual_subtitles.append([str(language), path_replace_reverse(os.path.join(os.path.dirname(file), subtitle))])
else:
with open(path_replace(os.path.join(os.path.dirname(file), subtitle)), 'r') as f:
text = list(islice(f, 20))
text = list(islice(f, 100))
text = ' '.join(text)
encoding = UnicodeDammit(text)
try: