mirror of
https://github.com/Dasemu/Transcriptarr.git
synced 2026-11-27 23:46:08 +00:00
Fix subtitle naming logic
This commit is contained in:
1 parent
b4d5d9c155
commit
3571cfa04d
1 file changed
+2
-2
@@ -729,8 +729,6 @@ def define_subtitle_language_naming(language: LanguageCode, type):
|
||||
"""
|
||||
if namesublang:
|
||||
return namesublang
|
||||
if transcribe_or_translate == 'translate':
|
||||
return 'eng'
|
||||
# If we are translating, then we ALWAYS output an english file.
|
||||
switch_dict = {
|
||||
"ISO_639_1": language.to_iso_639_1,
|
||||
@@ -739,6 +737,8 @@ def define_subtitle_language_naming(language: LanguageCode, type):
|
||||
"NAME": language.to_name,
|
||||
"NATIVE": lambda : language.to_name(in_english=False)
|
||||
}
|
||||
if transcribe_or_translate == 'translate':
|
||||
language = LanguageCode.from_string('eng')
|
||||
return switch_dict.get(type, language.to_name)()
|
||||
|
||||
def name_subtitle(file_path: str, language: LanguageCode) -> str:
|
||||
|
||||
Reference in new issue
Block a user