Skip to content

Commit

Permalink
fix(framework): Take region into account for i18n assets (#1985)
Browse files Browse the repository at this point in the history
  • Loading branch information
vladitasev committed Jul 27, 2020
1 parent f17cba3 commit 3b614ad
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/base/src/asset-registries/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ const fetchI18nBundle = async packageName => {
}

const language = getLocale().getLanguage();
const region = getLocale().getRegion();

let localeId = normalizeLocale(language);
let localeId = normalizeLocale(language + (region ? `-${region}` : ``));
while (localeId !== DEFAULT_LANGUAGE && !bundlesForPackage[localeId]) {
localeId = nextFallbackLocale(localeId);
}
Expand Down

0 comments on commit 3b614ad

Please sign in to comment.