-
Notifications
You must be signed in to change notification settings - Fork 177
Commit
In `PurchaseCompleted` we are passing a Flutter's `StoreTransaction` in the callback. This is very confusing but: - In Android `StoreTransaction` is what's returned after a successful purchase. This class has a nullable `orderId` - In Android `Transaction` is the transactions in the CustomerInfo. This class has a non-nullable `transactionIdentifier` The issue we are having is that in Flutter we only have one `StoreTransaction` with a non-nullable `transactionId`, and we are using it in both places, the `PurchaseCompleted` and `CustomerInfo`. I see several ways of fixing this: - Making transactionIdentifier nullable. I don’t like this. It’s breaking - Making transactionIdentifier an empty string. Fixing it in next major - Making transactionIdentifier an empty string, deprecating it and creating orderId which is nullable and the same as transactionIdentifier. We’ll have nullable orderIds in the customer info transactions where this object is also used. In Android we have two classes, one for CustomerInfo transactions (Transaction with non-nullable transactionId ) and StoreTransaction which is used for completed purchases - Making a copy of StoreTransaction and name it CompletedPurchase , but with a nullable transactionIdentifier. Also breaking since we need to modify the PurchaseCompleted callback to receive this object. Making a new callback won’t work because the broken `PurchaseCompleted will keep crashing. In this PR I am doing number 2, since it's the least breaking. This only affects apps using Amazon paywalls, which is not many. Will fix #1049
- Loading branch information
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.