mirror of
https://github.com/morpheus65535/bazarr.git
synced 2025-01-11 01:07:36 +08:00
don't check for language code if the subtitle file name is the same as the video name
if the subtitle file name is the same as the video name, it is pointless to check the language code
This commit is contained in:
parent
183fc8f7d3
commit
ca0123c036
1 changed files with 5 additions and 0 deletions
|
@ -605,6 +605,11 @@ def _search_external_subtitles(path, languages=None, only_one=False, scandir_gen
|
|||
if not INCLUDE_EXOTIC_SUBS and p_ext not in (".srt", ".ass", ".ssa", ".vtt"):
|
||||
continue
|
||||
|
||||
if p_root.lower() == fn_no_ext_lower:
|
||||
# skip check for language code is the subtitle file name is the same as the video name
|
||||
subtitles[p] = None
|
||||
continue
|
||||
|
||||
# extract potential forced/normal/default tag
|
||||
# fixme: duplicate from subtitlehelpers
|
||||
split_tag = p_root.rsplit('.', 1)
|
||||
|
|
Loading…
Reference in a new issue