ios - SKStoreProductViewController SKStoreProductViewControllerDelegate , no error handling? -
when nowadays skstoreproductviewcontroller in app, bad network conditions or in aeroplane mode, modal view not presented (because of course of study can retrieve info appstore), , there no error handling method in delegate.
so what's proper way handle network errors or no network in situation?
silly me, there's completion block can utilize this.
[storeviewcontroller loadproductwithparameters:parameters completionblock:^(bool result, nserror *error) { if (result) { [appdelegate.window.rootviewcontroller presentviewcontroller:storeviewcontroller animated:yes completion:nil]; } else { //error message } }];
ios ios5 app-store
No comments:
Post a Comment