Skip to content

fix(isMobilePhone): update Uzbekistan (uz-UZ) carrier prefixes#2728

Closed
xxiaoxiong wants to merge 1 commit into
validatorjs:masterfrom
xxiaoxiong:fix/uzbekistan-mobile-prefixes
Closed

fix(isMobilePhone): update Uzbekistan (uz-UZ) carrier prefixes#2728
xxiaoxiong wants to merge 1 commit into
validatorjs:masterfrom
xxiaoxiong:fix/uzbekistan-mobile-prefixes

Conversation

@xxiaoxiong
Copy link
Copy Markdown

@xxiaoxiong xxiaoxiong commented May 30, 2026

Summary

Updates the Uzbekistan (uz-UZ) mobile phone number regex to include recently allocated carrier prefixes (33, 55, 77).

Changes

  • src/lib/isCreditCard.js [wait — src/lib/isMobilePhone.js]: Updated uz-UZ regex from (6[125-79]|7[1-69]|88|9\d) to (33|55|6[125-79]|7[1-9]|88|9\d)

Why

The current regex only matches 61-62, 65-69, 71-76, 79, 88, 90-99. Newly assigned prefixes 33, 55, and 77 were missing, causing valid Uzbek phone numbers to be rejected.

Prefix sources:

  • 33, 55: New mobile carriers
  • 77: Previously unlisted (only 71-76, 79 were included)

Closes #2683

Fixes #2683

Add missing carrier prefixes 33 (Humans), 55, and 77 (Ucell) to
the Uzbekistan mobile phone regex. Also expand 7x range to 71-79
instead of 71-76/79 to include 77 and 78.
@codecov
Copy link
Copy Markdown

codecov Bot commented May 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (7fdc788) to head (ca3224b).

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #2728   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          114       114           
  Lines         2587      2587           
  Branches       656       656           
=========================================
  Hits          2587      2587           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@xxiaoxiong xxiaoxiong closed this May 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

isMobilePhone('uz-UZ') returns false for valid Uzbekistan carrier codes (e.g., 77)

1 participant