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

Retreave shipping address at Apple Pay Native Payment #140

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

kponda
Copy link

@kponda kponda commented Apr 9, 2020

No description provided.

@@ -174,6 +174,10 @@ class StripePayment {
final result = await _channel.invokeMethod('confirmSetupIntent', intent.toJson());
return SetupIntentResult.fromJson(result);
}

static openApplePaySetup() async {
Copy link
Owner

Choose a reason for hiding this comment

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

can you add some information why and where this is needed?

Copy link
Author

Choose a reason for hiding this comment

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

I need open ApplePaySetup in somecase and StripePaymentPlugin.m and TPSStripeManager.m implemented this. but I can't call this method and I add openApplePaySetup method in stripe_payment.dart file.

https://github.com/jonasbark/flutter_stripe_payment/blob/master/ios/Classes/StripePaymentPlugin.m#L65
https://github.com/jonasbark/flutter_stripe_payment/blob/master/ios/Classes/TPSStripeManager.m#L877

@klivin
Copy link

klivin commented Dec 2, 2020

This is necessary for any use case involving shipping...can we please merge this?

isoCountryCode: json['ISOCountryCode'] ?? "",
state: json['state'] ?? json['administrativeArea'] ?? "",
city: json['city'] ?? json['locality'] ?? "",
street: json['street'] ?? json['address1'] != null ? json['address1'] + json['address2'] : "",
Copy link

Choose a reason for hiding this comment

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

The following line breaks with exception:
street: json['street'] ?? json['address1'] != null ? json['address1'] + json['address2'] : "",
_TypeError (type 'String' is not a subtype of type 'bool')

Needs parens, so change to
json['street'] ?? (json['address1'] != null ? json['address1'] + json['address2'] : "")

tan-nad pushed a commit to tan-nad/stripe_payment that referenced this pull request Jun 16, 2021
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.

3 participants