3 ms·
The code is checking the region part of the locale, which is CN for china. The language code for chinese is zh.
by 33degrees 7y ago
The code is checking the region part of the locale, which is CN for china. The language code for chinese is zh.
- jakear 7y ago“en_US” is “American English”, not “English on a Phone in america”. The alternative “zh-*” codes are SG, TW, or HK. It’s checking if the user has their region set to “Mainland Chinese”, not That their phone is “Chinese on a phone in China”.
- 33degrees 7y agoActually, american english is "en-US", "en_US" means english with the region set to the US, at least on iOS. But yes, it is checking that their region is set to mainland china. https://developer.apple.com/library/archive/documentation/MacOSX/Conceptual/BPInternational/LanguageandLocaleIDs/LanguageandLocaleIDs.html#//apple_ref/doc/uid/10000171i-CH15-SW9 https://developer.apple.com/library/archive/documentation/Ma...
- larkeith 7y agoDidn't realize this, thank you for clarification!