Skip to content

Commit

Permalink
Shorten variable names
Browse files Browse the repository at this point in the history
  • Loading branch information
sarahkoop committed Nov 9, 2023
1 parent 59069e6 commit 4fd84d2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -263,21 +263,21 @@ void tokenize(PaymentData paymentData, GooglePayTokenizeCallback callback) {
* method should be invoked to tokenize the payment method to retrieve a
* {@link PaymentMethodNonce}
*
* @param googlePayPaymentAuthResult the result of {@link GooglePayLauncher#launch(GooglePayPaymentAuthRequest)}
* @param paymentAuthResult the result of {@link GooglePayLauncher#launch(GooglePayPaymentAuthRequest)}
* @param callback {@link GooglePayTokenizeCallback}
*/
public void tokenize(GooglePayPaymentAuthResult googlePayPaymentAuthResult,
public void tokenize(GooglePayPaymentAuthResult paymentAuthResult,
GooglePayTokenizeCallback callback) {
if (googlePayPaymentAuthResult.getPaymentData() != null) {
if (paymentAuthResult.getPaymentData() != null) {
braintreeClient.sendAnalyticsEvent("google-payment.authorized");
tokenize(googlePayPaymentAuthResult.getPaymentData(), callback);
} else if (googlePayPaymentAuthResult.getError() != null) {
if (googlePayPaymentAuthResult.getError() instanceof UserCanceledException) {
tokenize(paymentAuthResult.getPaymentData(), callback);
} else if (paymentAuthResult.getError() != null) {
if (paymentAuthResult.getError() instanceof UserCanceledException) {
braintreeClient.sendAnalyticsEvent("google-payment.canceled");
} else {
braintreeClient.sendAnalyticsEvent("google-payment.failed");
}
callback.onResult(null, googlePayPaymentAuthResult.getError());
callback.onResult(null, paymentAuthResult.getError());
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
*/
public interface GooglePayPaymentAuthRequestCallback {

void onResult(@Nullable GooglePayPaymentAuthRequest googlePayPaymentAuthRequest,
void onResult(@Nullable GooglePayPaymentAuthRequest paymentAuthRequest,
@Nullable Exception error);
}

0 comments on commit 4fd84d2

Please sign in to comment.