2 Replies
      Latest reply on Feb 25, 2019 8:06 AM by KMT
      bharris Level 1 Level 1 (0 points)
        I've been asked by Saudi Arabia to exclude some features sensitive in their country (specifically features identifying homosexuality, if your curious).

        So I'd like to localize the app based on which app store the user is connected to.

         

        I've tried using NSLocale this appears to be more closely tied to the country of localization the user picks on their device (in the same general area where they pick the language for the device)

         

        The problem with this, is that many people in Saudi Arabia buy their phones over seas (Great Britain being a common example) and they end up just changing the language to Arabic, but leaving the Locale as GB. Or they just leave it in English with a Locale of GB.

         

        So Locale seems like a poor choice for doing this type of localization. Is anyone aware of an API that lets you determine which store your device is connected to?

        • Re: How can I determine which app store a user's device is connected to?
          eskimo Apple Staff Apple Staff (12,285 points)

          There is no API to determine:

          • Which store the app was bought from

          • Which store the device is currently configured to use

          One option here is to ‘duplicate’ your app, remove the objected-to content from the copy, make that available in the objecting countries, and withdraw the original from those countries.

          Another option is to use the phone’s physical location to decide what to display.

          Share and Enjoy

          Quinn “The Eskimo!”
          Apple Developer Relations, Developer Technical Support, Core OS/Hardware
          let myEmail = "eskimo" + "1" + "@apple.com"

          • Re: How can I determine which app store a user's device is connected to?
            KMT Level 9 Level 9 (15,045 points)

            You find it simpler to just take that app off-sale (via rights/pricing in ASC) in whichever countries you wish to restrict sales.

             

            And yes, locale is a poor choice as it doesn't allow you the opportunity to bifurcate between a user's geographical postion vs. their home store. They can only download from their home store in any case.