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

Refactor canMakePayments to BillingWrapper #355

Open
beylmk opened this issue Sep 2, 2021 · 1 comment
Open

Refactor canMakePayments to BillingWrapper #355

beylmk opened this issue Sep 2, 2021 · 1 comment
Assignees
Labels

Comments

@beylmk
Copy link
Contributor

beylmk commented Sep 2, 2021

Currently, canMakePayments lives in Purchases. We will need to leave an API to call canMakePayments there, but should refactor the actual code into BillingWrapper to respect our blackboxing of store-specific code. The same will be needed for isBillingSupported and isFeatureSupported. This might require a Store parameter to be passed to the method, since it's static.

Additionally, we should add comments and/or perhaps errors to clarify that this method currently only exists for the Play store (there is no known implementation for Amazon at this point).

@vegaro
Copy link
Contributor

vegaro commented Nov 4, 2021

Just adding some more context here, because we were talking about it in grooming. We think for Amazon, returning true would be a good compromise. Apart from that, when we move the call to BillingWrapper, the call should be static, since it doesn't require an instance of BillingWrapper. Maybe it should live in a new class that's a static class, since BillingWrapper is not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants