fix locale detect error on mobile apps (#5956)

This commit is contained in:
Ricardo Santana
2020-04-27 17:38:57 +02:00
committed by GitHub
parent 94a15914d0
commit 93ef8495ca
@@ -17,7 +17,7 @@ export default {
detect() {
const { LocaleDetector } = NativeModules;
return LocaleDetector.locale.replace(/_/, '-');
return LocaleDetector.locale.replace(/[_-]/, '');
},
init: Function.prototype,