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

fix(receipts): ensuring there is a receipt #535

Merged
merged 1 commit into from
Mar 29, 2023
Merged

fix(receipts): ensuring there is a receipt #535

merged 1 commit into from
Mar 29, 2023

Conversation

bassrock
Copy link
Member

Summary

On iOS simulators when you are logged out of Apple, a system prompt will show if you request a receipt. Instead we should see if a recept exists first

PR Checklist:

  • Added Unit / UI tests
  • Self Review (review, clean up, documentation, run tests)
  • Basic Self QA

Screenshots

@bassrock bassrock requested a review from a team as a code owner March 29, 2023 19:20
@bassrock bassrock requested review from dskuza and CMasterson and removed request for a team March 29, 2023 19:20
Copy link
Collaborator

@Gio2018 Gio2018 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one comment @bassrock

@@ -27,6 +27,9 @@ class AppStoreReceiptService: NSObject, ReceiptService {
}

func send(_ product: Product?) async throws {
// First make sure a receipt even exists before we try and get one.
_ = try getReceipt()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wondering if, instead of calling getReceipt() twice, we can just handle the whole thing inside getReceipt() where we already check the existence on disk?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Gio2018 up to you. really this method is designed for that throws method in getReceipt

@Gio2018 Gio2018 self-requested a review March 29, 2023 19:43
@bassrock bassrock merged commit 5d321f7 into develop Mar 29, 2023
@bassrock bassrock deleted the receipts branch March 29, 2023 19:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants