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

Bug - not able to unset Stripe account #331

Open
vytautas-pranskunas- opened this issue Aug 24, 2021 · 2 comments
Open

Bug - not able to unset Stripe account #331

vytautas-pranskunas- opened this issue Aug 24, 2021 · 2 comments

Comments

@vytautas-pranskunas-
Copy link
Contributor

vytautas-pranskunas- commented Aug 24, 2021

hi @jonasbark Is there a way how to unset Stripe account?
Because now - once 3ds is triggered I am setting Stripe account. But after i need to unset it because otherways all other actions, like payment methods creation, will be made in that account...

I see in this post guy is doing this is setting it null to fight not corrrect authentication before each payment method creation. But in null safety version param is not nullable :(
https://medium.com/flutter-community/build-a-marketplace-in-your-flutter-app-and-accept-payments-using-stripe-and-firebase-72f3f7228625

I really need a way to reset that header otherways all integration just not correct.
Can you help? If needd I can help.
This is ONLY bug left which blocks us from going LIVE

Also i see it is easy fix I can even do PR because i see you are doing all it needs

 @ReactMethod
  public void setStripeAccount(final String stripeAccount) {
    ArgCheck.notEmptyString(mPublicKey);
    mStripeAccountId = stripeAccount;
    if (stripeAccount == null) {
      mStripe = new Stripe(getReactApplicationContext(), mPublicKey);
    } else {
      mStripe = new Stripe(getReactApplicationContext(), mPublicKey, stripeAccount);
    }
  }

the only bad stuff is this:

  static void setStripeAccount(String stripeAccount) {
    _channel.invokeMethod('setStripeAccount', {"stripeAccount": stripeAccount});
  }

String is not nullable :(

@vytautas-pranskunas-
Copy link
Contributor Author

Here you go: #332
Can you merge it please?

@vytautas-pranskunas- vytautas-pranskunas- changed the title I need a way how to unset Stripe account Bug - not able to unset Stripe account Aug 25, 2021
@vytautas-pranskunas-
Copy link
Contributor Author

@jonasbark would you be able to merge this small PR please?

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

No branches or pull requests

1 participant