Issue
I recently updated the InAppPurchase plugin in flutter. The update is breaking the code.
I am unable get past purchases using the InAppPurchase instance.Anyone know how to retreive the past purchase?
Final QueryPurchaseDetailsResponse purchaseResponse =await _inAppPurchase.queryPastPurchases();
Solution
try to use:
final InAppPurchase _inAppPurchase = InAppPurchase.instance;
await _inAppPurchase.restorePurchases();
Answered By – Reham Alraee
Answer Checked By – Katrina (FlutterFixes Volunteer)