aboutsummaryrefslogtreecommitdiffhomepage
path: root/custom_libs/subliminal_patch/core.py
diff options
context:
space:
mode:
authormorpheus65535 <[email protected]>2024-08-27 21:51:14 -0400
committermorpheus65535 <[email protected]>2024-08-27 21:51:14 -0400
commitf1f3850f9e0f30403f87a359143dfe366b479e37 (patch)
treefc035dede3b11646f93c89d7723c4db0951fdf62 /custom_libs/subliminal_patch/core.py
parent74f2c6646404b76821146e9b58bed12c53fc1186 (diff)
downloadbazarr-f1f3850f9e0f30403f87a359143dfe366b479e37.tar.gz
bazarr-f1f3850f9e0f30403f87a359143dfe366b479e37.zip
no log: small fixes to my latest commitv1.4.4-beta.36
Diffstat (limited to 'custom_libs/subliminal_patch/core.py')
-rw-r--r--custom_libs/subliminal_patch/core.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/custom_libs/subliminal_patch/core.py b/custom_libs/subliminal_patch/core.py
index f0d7f3618..0fc2ac0a7 100644
--- a/custom_libs/subliminal_patch/core.py
+++ b/custom_libs/subliminal_patch/core.py
@@ -1213,7 +1213,10 @@ def save_subtitles(file_path, subtitles, single=False, directory=None, chmod=Non
continue
# create subtitle path
- if subtitle.text and parse_for_hi_regex(subtitle_text=subtitle.text, alpha3_language=subtitle.language.alpha3):
+ if subtitle.text and parse_for_hi_regex(subtitle_text=subtitle.text,
+ alpha3_language=subtitle.language.alpha3 if
+ (hasattr(subtitle, 'language') and hasattr(subtitle.language, 'alpha3'))
+ else None):
subtitle.language.hi = True
subtitle_path = get_subtitle_path(file_path, None if single else subtitle.language,
forced_tag=subtitle.language.forced,