Hi everyone. I am now testing in-app purchases within my app. I've ran into a problem when user purchases 1 month subscription (which lasts for 3 minutes in sandbox) and then after 3 minutes my app locks premium features if app is opened and actively used. I decide if premium features should be unlocked by retrieving expiration date of subscription and comparing it to now. This does not happen if I restart the app because then StoreKit completes pending renewal transactions in didFinishLaunchingWithOptions. Yes, the isPremium variable is checking for expiry date every time it's being accessed via getter. Should I decide isPremium state once in didFinishLaunchingWithOptions after pending transactions complete?
But what if app is not "unloaded" from memory for a long time? Then isPremium will be true unless app restarts.
Maybe I can put StoreKit's complete transactions in applicationDidBecomeActive? Though in every guideline they say it should be in didFinishLaunchingWithOptions. Or maybe I have another flaw in my in-app purchases design? Thank you.