HomeiOS Developmentswift - In IOS dev,concerning the SKPaymentQueue.default infomation concern

swift – In IOS dev,concerning the SKPaymentQueue.default infomation concern


I attempt to use StoreKit API get present App Retailer‘s area,it could actually work,however not all the time proper.

            if #out there(iOS 13, *){
                let queue = SKPaymentQueue.default()
                if let storefront = queue.storefront {
                    let countryCode = storefront.countryCode
                    let identifier = storefront.identifier
                    print("Nation Code: (countryCode)")
                    print("Identifier: (identifier)")
                } else {
                    print("Did not get storefront data")
                }
             }

My present account is China account,the nation code and identifier return “CHN” and “143465”,it appears proper.
after which i simply change the app retailer account(not icould),the brand new logined account is Americal account,however the nation code and identifer nonetheless return “CHN” and “143465”,is inaccurate.This is why?and the way am i able to repair this concern?

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments