MOBILE-4591 lang: Fix parent language strings overriden by mistake

main
Dani Palou 2024-08-05 09:20:55 +02:00
parent a7536cc9a3
commit 392351849b
1 changed files with 4 additions and 1 deletions

View File

@ -599,7 +599,10 @@ export class CoreLangProvider {
// Merge parent translations with the child ones.
const parentTranslations = Translate.translations[fallbackLang] ?? await this.readLangFile(fallbackLang);
const mergedData = Object.assign(parentTranslations, data);
const mergedData = {
...parentTranslations,
...data,
};
Object.assign(data, mergedData);
} catch {