File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed
firestore-stripe-payments/functions/src Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -106,7 +106,7 @@ exports.createCheckoutSession = functions.firestore
106
106
payment_method_types,
107
107
shipping_rates = [ ] ,
108
108
metadata = { } ,
109
- automatic_payment_methods = { enabled : true } ,
109
+ automatic_payment_methods = { enabled : true } ,
110
110
automatic_tax = false ,
111
111
tax_rates = [ ] ,
112
112
tax_id_collection = false ,
@@ -233,13 +233,17 @@ exports.createCheckoutSession = functions.firestore
233
233
currency,
234
234
customer,
235
235
metadata,
236
- }
236
+ } ;
237
237
if ( payment_method_types ) {
238
- paymentIntentCreateParams . payment_method_types = payment_method_types ;
238
+ paymentIntentCreateParams . payment_method_types =
239
+ payment_method_types ;
239
240
} else {
240
- paymentIntentCreateParams . automatic_payment_methods = automatic_payment_methods ;
241
+ paymentIntentCreateParams . automatic_payment_methods =
242
+ automatic_payment_methods ;
241
243
}
242
- const paymentIntent = await stripe . paymentIntents . create ( paymentIntentCreateParams ) ;
244
+ const paymentIntent = await stripe . paymentIntents . create (
245
+ paymentIntentCreateParams
246
+ ) ;
243
247
paymentIntentClientSecret = paymentIntent . client_secret ;
244
248
} else if ( mode === 'setup' ) {
245
249
const setupIntent = await stripe . setupIntents . create ( {
You can’t perform that action at this time.
0 commit comments