pikaju / flutter-braintree

Flutter plugin that wraps the native Braintree SDKs. Enables payments with credit cards, PayPal, Google Pay and more.
https://pub.dev/packages/flutter_braintree
MIT License
64 stars 119 forks source link

Dont Redirect to App in iOs 13 #39

Closed adriancsbna closed 1 year ago

adriancsbna commented 4 years ago

Hello

I have updated the plugin to version 1.1.0 in two apps, and in iOs 13, in both cases, when you perform 3D Secure authentication in sandbox mode, the web does not redirect you to the App.

A big blue button appears that tells you that it redirects you to the app if it doesn't do it automatically, but pressing it doesn't redirect you.

You can only get out of there by pressing DONE and the app interprets it as having canceled it.

Do you know what this error could be due to?

Thank you very much a greeting Adrian Casabuena

marcioadr88 commented 3 years ago

same is happening to me, any workaround?

nicolobozzato commented 3 years ago

There is any workaround for this?

nicolobozzato commented 3 years ago

I fixed it for me. My problem is that I followed the package example and wrote this in the AppDelegate.swift

` override func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool { if url.scheme == "com.example.flutterBraintreeExample.payments" { return BTAppSwitch.handleOpen(url, options:options) }

    return false
}`

instead of this

func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool { if url.scheme?.localizedCaseInsensitiveCompare("com.example.flutterBraintreeExample.payments") == .orderedSame { return BTAppSwitch.handleOpen(url, options: options) } return false }

like I should have looked and is shown here https://developers.braintreepayments.com/guides/paypal/client-side/ios/v4

pikaju commented 1 year ago

Please try the latest version and reopen if the issue persists.