SKPaymentQueue addTransactionObserver asking for App Store password on startup after in-app purchase

后端 未结 14 1070
耶瑟儿~
耶瑟儿~ 2020-12-01 04:46

My app is using in-app purchases, and most of my users can purchase just fine without any problems. For these folks, my app downloads the content after the purchase succeeds

相关标签:
14条回答
  • 2020-12-01 05:48

    There is a problem called the "endless loop". It was big issue back in the early days of auto renewables when, for about a week, the servers did not limit renewals to 5. A device that gets a transaction and doesn't call finishTransaction will get that transaction delivered to the device about once a week until that particular test user logs in and calls finishTransaction. If you switch to airplane mode you can 'clear' those transactions for another week - but they come back.

    0 讨论(0)
  • 2020-12-01 05:49

    Check for the following as I had it in my viewDidLoad method. I had an app rejected when apple wanted me to go from non-consumable to consumable, however I left the following line in my viewDidLoad method: (I thought the password prompt was a issue with swapping from the test user to normal user back to the test user)

    [[SKPaymentQueue defaultQueue] restoreCompletedTransactions];
    

    Once removed the request for password stopped.

    And I have left: [[SKPaymentQueue defaultQueue] addTransactionObserver:self]; in and the app has now been approved just fine.

    0 讨论(0)
提交回复
热议问题