Skip to content
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

Paywall Result should return the correct status #986

Open
5 tasks done
joshuadeguzman opened this issue Feb 21, 2024 · 3 comments
Open
5 tasks done

Paywall Result should return the correct status #986

joshuadeguzman opened this issue Feb 21, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@joshuadeguzman
Copy link

joshuadeguzman commented Feb 21, 2024

‼️ Required data ‼️

Do not remove any of the steps from the template below. If a step is not applicable to your issue, please leave that step empty.

There are a lot of things that can contribute to things not working. Having a very basic understanding of your environment will help us understand your issue faster!

Environment

  • Flutter 3.16.9
  • purchases_flutter 6.20.0
  • iOS
  • Every time

Steps to reproduce

  1. Login user A, buy a subscription
  2. Login user B, buy a subscription without changing Apple ID (or sandbox user)
  3. User sees a native iOS dialog
  4. Logs says RevenueUI returned a PaywallResult.cancelled

Expected

  • RevenueUI should return a PaywallResult.error

Actual

  • RevenueUI should return a PaywallResult.canceled

Describe the bug

  • We're using the latest version of RevenueCat UI SDK that has the presentPaywall() method
  • We're limiting users to one user account == one Apple ID account, therefore the user sees the error below:

Xnapper-2024-02-21-22 18 20

  • However, although the message on the iOS dialog is correct, the Future<PaywallResult> is PaywallResult. canceled, which is incorrect because we expect that the .cancelled is only used when the user cancels the flow
  • And, we needed to handle error states better in the app
@joshuadeguzman joshuadeguzman added the bug Something isn't working label Feb 21, 2024
@RCGitBot
Copy link
Contributor

👀 We've just linked this issue to our internal tracker and notified the team. Thank you for reporting, we're checking this out!

@mirkancal
Copy link

I thought it would be restored and return restored state, thank you for opening the issue.

@joshuadeguzman
Copy link
Author

Thanks guys!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants