I was wondering how others deal with the in-app purchase calls when the user has their network disabled or is out of range of wifi?
For example, I initialize my store when I enter an intro page that contains the “store” button. The initialize in this case just calls store.init(“apple”,shop.transactionCallback), which appears to generate no errors.
If the user presses the “store” button, the I call a “setupMyStore” function that checks if the store.isActive and then tries to load the products like this:
if store.isActive then if store.canLoadProducts then store.loadProducts( currentProductList, shop.loadProductsCallback ) print("after store.loadProducts, awaiting callback") end
Right here in my output logs on the device is where I hang up. The callback for loadProducts never gets called because (I am assuming) my networking is offline or wifi is out of range and the network is trying to connect to the store.
So how do you guys normally approach this? Do you do a check before allowing entry into any store.* functions if the network is available and report this as a no-no?
Curious minds gotta know…
Regards,
Paul