Open thuautp opened 1 week ago
Here is the complete original debugging information that we provided including screenshots:
The error message is coming directly from Stripe.com (JS):
This is because the parameter "name"
sent to Stripe is empty:
The Stripe plugin is passing first name and last name, if they are set - otherwise a value from a hidden data property: https://github.com/woocommerce/woocommerce-gateway-stripe/blob/09bac72b1c0953d2eb3610e2cdd3eb374dae5cd7/assets/js/stripe.js#L485-L491
The hidden data property does not exist on the checkout page in this scenario:
I already tried adding the hidden element #stripe-payment-data
to the page with a dummy value in the full-name
data property, but it did not resolve the issue.
I also tried setting a dummy value for the default value in wc_stripe_params.billing_first_name
, but it did not resolve the issue.
The wc_stripe_params
actually contain an error message "invalid_owner_name"
that is supposed to say "Billing First Name and Last Name are required.", but it is never triggered.
→ It seems the plugin was already trying to correctly handle this case, but it is no longer working in the new UPE checkout and the code in the plugin needs to be updated.
Reported in 8856059-zen
Is your feature request related to a problem? Please describe.
If the email address and/or first name are not filled in, SEPA (direct debit) payers see a cryptic message in the checkout: "Missing required param: billing_details[name]".
Describe the solution you'd like
The regular WooCommerce checkout form validation error message for email and first name fields should appear, as with the other payment methods.
Describe alternatives you've considered
From the ticket above, the user mentioned:
Additional context I can replicate this error message with SEPA on my test site.