mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-06-30 19:36:25 +08:00
Add extra logs
This commit is contained in:
@ -143,6 +143,9 @@ class _PurchaseWidgetState extends State<PurchaseWidget> {
|
|||||||
|
|
||||||
void _listenToPurchaseUpdated(List<PurchaseDetails> purchaseDetailsList) {
|
void _listenToPurchaseUpdated(List<PurchaseDetails> purchaseDetailsList) {
|
||||||
purchaseDetailsList.forEach((PurchaseDetails purchaseDetails) async {
|
purchaseDetailsList.forEach((PurchaseDetails purchaseDetails) async {
|
||||||
|
Log.i(
|
||||||
|
"PurchaseDetailsUpdated: {productID: ${purchaseDetails.productID}, purchaseID: ${purchaseDetails.purchaseID}, status: ${purchaseDetails.status}");
|
||||||
|
|
||||||
if (purchaseDetails.status == PurchaseStatus.pending) {
|
if (purchaseDetails.status == PurchaseStatus.pending) {
|
||||||
//showPendingUI();
|
//showPendingUI();
|
||||||
Log.i("Pending - ${purchaseDetails.productID}");
|
Log.i("Pending - ${purchaseDetails.productID}");
|
||||||
@ -182,6 +185,10 @@ class _PurchaseWidgetState extends State<PurchaseWidget> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void _handleError(String err) {
|
void _handleError(String err) {
|
||||||
|
if (Platform.isAndroid) {
|
||||||
|
Log.e(err);
|
||||||
|
return;
|
||||||
|
}
|
||||||
var dialog = PurchaseFailedDialog(err);
|
var dialog = PurchaseFailedDialog(err);
|
||||||
showDialog(context: context, builder: (context) => dialog);
|
showDialog(context: context, builder: (context) => dialog);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user