-
Notifications
You must be signed in to change notification settings - Fork 9.8k
[in_app_purchase] Fix wrong _pendingCompletePurchase flag value #2504
Conversation
When purchasing the flag is always set to false as we were not use the setter that was setting _pendingCompletePurchase to true when purchasing.
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.
Thanks for the PR! The fix is great! Would you mind add some tests before we land the PR?
Adding unit-test cases to validate the new results for pendingCompletePurchase flag
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.
LGTM! Thank you very much!
np :) |
To clarify, now If this is intended then the name may be misleading (after migration to Play Billing Library 2.0, I thought on Android it means 'not yet acknowledged'). Anyway, this may only result in redundant |
Yea I was thinking about that use case as well. But then as you said extra calls to |
@d0bry The purchases are not considered completed unless a |
@cyanglaz Yes, I just meant that |
Description
When purchasing the _pendingCompletePurchase flag is always set to false as we were not using the setter that was setting _pendingCompletePurchase to true when purchasing status was true.
Related Issues
flutter/flutter#49083
Checklist
Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes (
[x]
). This will ensure a smooth and quick review process.///
).flutter analyze
) does not report any problems on my PR.Breaking Change
Does your PR require plugin users to manually update their apps to accommodate your change?