Don't overwrite global 'locale' variable in local scopes.
Use underscore for fallback language to match the supported locals extracted from path.