Commit 9dedf5f9 by Vladislav Lagunov

[gettext] Исправлена ошибка

parent e8bdeb08
...@@ -45,7 +45,7 @@ export class Translations { ...@@ -45,7 +45,7 @@ export class Translations {
locale = locale.replace(/_/, '-'); locale = locale.replace(/_/, '-');
if (!(locale in this.data)) { if (!(locale in this.data)) {
// Не найдена локаль в `this.data` // Не найдена локаль в `this.data`
return n === 1 ? singular_key : plural_key!; return n === 1 ? singular_key : (plural_key || singular_key);
} }
const key = context ? context + CONTEXT_DELIMITER + singular_key : singular_key; const key = context ? context + CONTEXT_DELIMITER + singular_key : singular_key;
const dict = this.data[locale]; const dict = this.data[locale];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment