#tallmanpapi

1 messages · Page 1 of 1 (latest)

cerulean ledgeBOT
keen reef
#

Hi! Let me help you with this.

#

What do you mean by "not working" exactly?

#

Also, this is not really a Stripe-related question.

ember pine
#

Oh, you're right actually..

#

Wait let me transform it in to a more Stripe related question.

#

So how does it normally work to call a function with the switch case made by Stripe? If you know what I mean.

#

Stripe shows us a switch case to use, but how would they expect us to make us of it?

#

@keen reef

keen reef
#

You don't have to use switch. You can check the value of body.type in any way you prefer, if you need to.

ember pine
#

Okay, but when we want to check for 'payment_method.succeeded' for example, they tell us to use a switch case right?

#

Do they expect us to pass in here, like what is allowed? I am trying to understand this so I know what I can do with it, you know what I mean.

keen reef
#

It doesn't matter, it's just what the person that was creating the example code decided to use, but it's irrelevant to Stripe.

#

Are you a JavaScript engineer?

ember pine
#

No.

#

Thank you though. I don't think you can help me with my out-of-scope question. Have a nice day.

keen reef
#

No worries, you too!