-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvements on error handling #69
base: main
Are you sure you want to change the base?
Conversation
STORE_PROBLEM(2010), | ||
INVALID_RECEIPT(2011), | ||
REQUEST_FAILED(2012), | ||
PRODUCT_PURCHASED_ALREADY(2013); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should include system error and restore errors here?
} | ||
case let .failure(error): | ||
_result(FlutterError.productIdentifierError(error.localizedDescription)) | ||
_result(FlutterError.productIdentifierError(error)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we update the example to denote how to handle the errors?
BillingClient.BillingResponseCode.USER_CANCELED -> PURCHASE_CANCELLED | ||
BillingClient.BillingResponseCode.ITEM_UNAVAILABLE -> PRODUCT_NOT_AVAILABLE | ||
BillingClient.BillingResponseCode.DEVELOPER_ERROR -> INVALID_PURCHASE | ||
BillingClient.BillingResponseCode.ITEM_ALREADY_OWNED -> PRODUCT_PURCHASED_ALREADY |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add the corresponding error codes in dart as well?
BILLING_UNAVAILABLE(2021), | ||
ITEM_UNAVAILABLE(2022), | ||
ITEM_NOT_OWNED(2023), | ||
ITEM_ALREADY_OWNED(2024), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should add these right?
… enum values to pass
Quality Gate passedThe SonarCloud Quality Gate passed, but some issues were introduced. 3 New issues |
No description provided.