Skip to content

Commit

Permalink
Only load English as fallback localization
Browse files Browse the repository at this point in the history
Until we configure a translation management system, English is the only localization with complete coverage including OpenHistoricalMap’s custom strings.
  • Loading branch information
1ec5 committed Mar 23, 2024
1 parent 7892786 commit a0eff70
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion modules/core/localizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,9 @@ export function coreLocalizer() {
indexes.forEach((index, i) => {
// Will always return the index for `en` if nothing else
const fullCoverageIndex = _localeCodes.findIndex(function(locale) {
return index[locale] && index[locale].pct === 1;
// Only English contains everything including the OpenHistoricalMap additions, because we haven’t set up a translation management system yet.
// https://github.com/OpenHistoricalMap/issues/issues/470
return locale === 'en' && index[locale] && index[locale].pct === 1;
});
// We only need to load locales up until we find one with full coverage
_localeCodes.slice(0, fullCoverageIndex + 1).forEach(function(code) {
Expand Down

0 comments on commit a0eff70

Please sign in to comment.