Merge pull request #3002 from noctux/fix-custom-languages-for-engines

[fix] use engine-type when looking up supported_languages from JSON files
This commit is contained in:
Noémi Ványi 2021-10-10 14:47:35 +02:00 committed by GitHub
commit c3034bd883
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -108,8 +108,8 @@ def load_engine(engine_data):
sys.exit(1)
# assign supported languages from json file
if engine_data['name'] in ENGINES_LANGUAGES:
setattr(engine, 'supported_languages', ENGINES_LANGUAGES[engine_data['name']])
if engine_data['engine'] in ENGINES_LANGUAGES:
setattr(engine, 'supported_languages', ENGINES_LANGUAGES[engine_data['engine']])
# find custom aliases for non standard language codes
if hasattr(engine, 'supported_languages'):