-
Notifications
You must be signed in to change notification settings - Fork 201
Description
Bug report
- Extension name: invertase/stripe-firebase-extensions
Describe the bug
after creating the customer and successfully made a checkout session, the extension rerun, updating the customer phone with the payment method data, that could have an empty value. That results in a wrong update of the correct phone number with null.
To Reproduce
Just try to create a customer and do a checkout session paying with credit card, you will notice in strupe events multiple actions on the profile, the last of them update the customer with a null phone number.
the problem is in the firestore-stripe-payments/functions/src/index.ts at row 513
const copyBillingDetailsToCustomer = async ( payment_method: Stripe.PaymentMethod ): Promise<void> => { const customer = payment_method.customer as string; const { name, phone, address } = payment_method.billing_details; await stripe.customers.update(customer, { name, phone, address }); };
KR
Nic
Metadata
Metadata
Assignees
Labels
Type
Projects
Status