We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I am using Google Pay isReadyToPay method always returns false. When does method returns false or true? Is Google Pay connected to the Locale?
mPaymentsClient = Wallet.getPaymentsClient(activity, new Wallet.WalletOptions .Builder() .setEnvironment(WalletConstants.ENVIRONMENT_TEST) .build()); IsReadyToPayRequest request = IsReadyToPayRequest.newBuilder() .addAllowedPaymentMethod(WalletConstants.PAYMENT_METHOD_CARD) .addAllowedPaymentMethod(WalletConstants.PAYMENT_METHOD_TOKENIZED_CARD) .build(); Task<Boolean> task = mPaymentsClient.isReadyToPay(request); task.addOnCompleteListener( new OnCompleteListener<Boolean>() { public void onComplete(Task<Boolean> task) { try { boolean result = task.getResult(ApiException.class); if (result == true) { //show Google as payment option } else { //hide Google as payment option } } catch (ApiException exception) { } } });
The text was updated successfully, but these errors were encountered:
me too
Sorry, something went wrong.
Check whether the above code is added in manifest file or not. Add in manifest file, hope it will work.
how to fix it?
No branches or pull requests
I am using Google Pay isReadyToPay method always returns false. When does method returns false or true? Is Google Pay connected to the Locale?
The text was updated successfully, but these errors were encountered: