Closed wasiquehaider closed 3 years ago
Hi @wasiquehaider
Can you tell me how was that issue resolved or how you get purchases in IOS?
Hi @wasiquehaider
Can you tell me how was that issue resolved or how you get purchases in IOS?
I was not mounting the in app purchase module at the root level thats why.
Version of react-native-iap
5.2.14
Version of react-native
0.63.3
Platforms you faced the error (IOS or Android or both?)
IOS
Expected behavior
return response on calling getAvailablePurchases / getPurchaseHistory in try/catch block
Actual behavior
returns the response in xcode console but not in try/catch block.
Tested environment (Emulator? Real Device?)
Real Device
Steps to reproduce the behavior
Call this function on IOS
getAvailablePurchases = async () => { try { const purchases = await getAvailablePurchases(); const newState = {premium: false, ads: true}; let restoredTitles = [];
}