From d735f397d865e2b0ce8ccbba25cdd3a334a0e411 Mon Sep 17 00:00:00 2001 From: MichaelDvP Date: Sat, 21 Jan 2023 14:22:49 +0100 Subject: [PATCH] fix crash with non-en language --- src/helpers.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/helpers.cpp b/src/helpers.cpp index f9f3dfc9b..071125577 100644 --- a/src/helpers.cpp +++ b/src/helpers.cpp @@ -729,7 +729,7 @@ const char * Helpers::translated_word(const char * const * strings, const bool f } // see how many translations we have for this entity. if there is no translation for this, revert to EN - if (force_en || (Helpers::count_items(strings) >= language_index + 1 && strlen(strings[language_index]))) { + if (!force_en && (Helpers::count_items(strings) >= language_index + 1 && strlen(strings[language_index]))) { index = language_index; } return strings[index];