iOS: fix locale return nil in some case
This commit is contained in:
parent
b4493ef777
commit
98c3bc6668
@ -92,8 +92,8 @@ - (instancetype)init {
|
||||
@"hasNotch": @(hasNotch()),
|
||||
@"deviceBrand": @"Apple",
|
||||
@"deviceModel": platform,
|
||||
@"localeLanguage": [[NSLocale currentLocale] objectForKey:NSLocaleLanguageCode],
|
||||
@"localeCountry": [[NSLocale currentLocale] objectForKey:NSLocaleCountryCode],
|
||||
@"localeLanguage": [[NSLocale currentLocale] objectForKey:NSLocaleLanguageCode] ?: @"",
|
||||
@"localeCountry": [[NSLocale currentLocale] objectForKey:NSLocaleCountryCode] ?: @"",
|
||||
}.mutableCopy;
|
||||
self.registry = [[DoricRegistry alloc] initWithJSEngine:self];
|
||||
[self ensureRunOnJSThread:^() {
|
||||
|
Reference in New Issue
Block a user