paypalPayment method

  1. @override
Future<PayPalAccountNonce?> paypalPayment(
  1. PayPalRequest request
)
override

Implementation

@override
Future<PayPalAccountNonce?> paypalPayment(PayPalRequest request) async {
  final String? res = await methodChannel.invokeMethod<String>(
      BraintreePaymentConstants.paypalPaymentMethodKey, request.toJson());
  if (res != null) {
    final json = jsonDecode(res);
    return PayPalAccountNonce.fromJson(json);
  } else {
    return null;
  }
}