From 46d6fd5506fdeab4a65c02774c61918d38c64c9e Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Wed, 31 May 2023 13:40:08 +0200 Subject: [PATCH] fix: update language display [DHIS2-15293] (#1262) --- src/AppWrapper.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/AppWrapper.js b/src/AppWrapper.js index e1dab50c..881f4158 100644 --- a/src/AppWrapper.js +++ b/src/AppWrapper.js @@ -30,11 +30,17 @@ const AppWrapper = () => { })) const uiLocales = (results[1] || []).map((locale) => ({ id: locale.locale, - displayName: locale.name, + displayName: + locale.name === locale.displayName + ? locale.name + : `${locale.name} — ${locale.displayName}`, })) const dbLocales = (results[2] || []).map((locale) => ({ id: locale.locale, - displayName: locale.name, + displayName: + locale.name === locale.displayName + ? locale.name + : `${locale.name} — ${locale.displayName}`, })) const systemDefault = { ...results[4] }