Browse Source

fix locale detect error on mobile apps (#5956)

j8
Ricardo Santana 5 years ago
parent
commit
93ef8495ca
No account linked to committer's email address
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      react/features/base/i18n/languageDetector.native.js

+ 1
- 1
react/features/base/i18n/languageDetector.native.js View File

17
     detect() {
17
     detect() {
18
         const { LocaleDetector } = NativeModules;
18
         const { LocaleDetector } = NativeModules;
19
 
19
 
20
-        return LocaleDetector.locale.replace(/_/, '-');
20
+        return LocaleDetector.locale.replace(/[_-]/, '');
21
     },
21
     },
22
 
22
 
23
     init: Function.prototype,
23
     init: Function.prototype,

Loading…
Cancel
Save