setRestored method
dynamic
setRestored(
- PurchaseDetails details
Implementation
setRestored(PurchaseDetails details) {
log("Restoring Product =============> ${details.productID}");
Map plan = {
"ProductId": details.productID,
"PurchaseId": details.purchaseID,
"Status": details.status.name,
"PurchaseDate": details.transactionDate,
};
subPref!.setBool(
"subscription",
true,
);
subPref!.setString(
"plan",
json.encode(plan),
);
Future.microtask(() {
isSubscribed = true;
});
}