purchases-android
purchases-android copied to clipboard
Allow passing old purchase id and GoogleReplacementMode to paywalls purchase flow
Checklist
- [x] If applicable, unit tests
- [ ] If applicable, create follow-up issues for
purchases-iosand hybrids
Motivation
As per this issue #2479 , setting the GoogleReplacementMode is currently not possible when using Paywalls v2. This PR allows developers to change the proration mode and pass the old purchase id to the purchasing flow.
Description
- Add new
ReplaceProductDatadata class - Pass data to
PurchaseParamsBuilderon purchase - Extend
PaywallOptionsandPaywallDialogOptionsto support new parameter - Add tests in
PaywallViewModelTestto verify correct parameters are passed to purchase flow