slight refactor of `loadLocale()'