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 28, 2020
1 parent afdd506 commit a75c96d
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 @@ -56,8 +56,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 a75c96d

Please sign in to comment.