mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-07-21 19:24:15 +00:00
Squashed commit of the following:
commit 6d74f87db332fd28c7522cabc0f96a390d36e64f
Author: SabreCat <sabe@habitica.com>
Date: Fri Aug 18 20:04:52 2023 -0500
fix(i18n): default to EN for empties
This commit is contained in:
parent
e8f5958f77
commit
c71f0b3fda
1 changed files with 2 additions and 1 deletions
|
|
@ -50,7 +50,8 @@ approvedLanguages.forEach(file => {
|
|||
if (file === 'en' || fs.statSync(path.join(localePath, file)).isDirectory() === false) return;
|
||||
_loadTranslations(file);
|
||||
|
||||
// Merge missing strings from english
|
||||
// Strip empty strings, then merge missing strings from english
|
||||
translations[file] = _.pickBy(translations[file], string => string !== '');
|
||||
_.defaults(translations[file], translations.en);
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue