-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[$250] Card - 10 digit phone number isn't accepted when the member adds shipping details #50282
Comments
Triggered auto assignment to @lschurr ( |
We think that this bug might be related to #wave-control |
@lschurr FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors |
Edited by proposal-police: This proposal was edited at 2024-10-06 19:06:35 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.10 digit phone number isn't accepted when the member adds shipping details. What is the root cause of that problem?The validation functions we use to check phone number is wrong, this gives us the error on the frontend App/src/pages/MissingPersonalDetails/substeps/PhoneNumber.tsx Lines 39 to 41 in 99f280b
The above validation will give errors for 10 digit numbers. What changes do you think we should make in order to solve the problem?We should use the validation logic we have on the App/src/pages/signin/LoginForm/BaseLoginForm.tsx Lines 77 to 82 in 99f280b
We should use the same logic for the add shipping details RHP too, this way we make sure that we are validating against the correct value and using the current functions to validate. If the same bug exists at other places we should fix them too
const phoneLogin = LoginUtils.appendCountryCode(LoginUtils.getPhoneNumberWithoutSpecialChars(values[INPUT_IDS.PHONE_NUMBER]));
const parsedPhoneNumber = PhoneNumberUtils.parsePhoneNumber(phoneNumber);
if (!parsedPhoneNumber.possible) {
errors[INPUT_IDS.PHONE_NUMBER] = translate('bankAccount.error.phoneNumber');
What alternative solutions did you explore? (Optional) |
Job added to Upwork: https://www.upwork.com/jobs/~021843278716830129573 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @rayane-djouah ( |
@rayane-djouah my proposal is here above |
ProposalPlease re-state the problem that we are trying to solve in this issue.10 digit phone number isn't accepted when the member adds shipping details. Only 8 digits are accepted. What is the root cause of that problem?On the sign-in page, Lines 8 to 12 in 7947b8e
After the user is logged in, if the user is not in USA, the Line 23 in 7947b8e
App/src/pages/MissingPersonalDetails/substeps/PhoneNumber.tsx Lines 39 to 40 in 7947b8e
What changes do you think we should make in order to solve the problem?In the other place of phone number input in bank account flow, we use
App/src/pages/MissingPersonalDetails/substeps/PhoneNumber.tsx Lines 39 to 40 in 7947b8e
OPTIONAL: We also can limit the US address in the address step by adding What alternative solutions did you explore? (Optional) |
@rayane-djouah could you review the proposals here? Thanks! |
Reviewing 👀 |
@lschurr @IuliiaHerets I don't believe this is a bug. The app automatically appends the country code to the phone number based on the user's IP address during validation. If the user is not in the USA, the corresponding country code for their location will be added to the number 8005555555 and then validated. For users in the USA, using 8005555555 does not give an error. To use a USA phone number from outside the US, the user needs to add +1 before the number; thus, +18005555555 should work without any errors. |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
@lschurr I think we can close this issue |
@lschurr, @rayane-djouah Whoops! This issue is 2 days overdue. Let's get this updated quick! |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 9.0.44-8
Reproducible in staging?: Y
Reproducible in production?: Y
Issue was found when executing this PR: #49452
Issue reported by: Applause Internal Team
Action Performed:
Expected Result:
10 digit phone number should be accepted.
Actual Result:
10 digit phone number isn't accepted when the member adds shipping details. Only 8 digits are accepted.
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6624081_1728026724870.b.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @rayane-djouahThe text was updated successfully, but these errors were encountered: