-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
feat(isMobilePhone) Fix Mobile Phone Regex Pakistan(PK) #1778
Conversation
Update the regex to validate mobile numbers correctly for Pakistan
Codecov Report
@@ Coverage Diff @@
## master #1778 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 102 102
Lines 2029 2029
Branches 457 457
=========================================
Hits 2029 2029
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your PR @hammad20120 looks like your regex is also validating landline numbers. Please check and address my comment below!
Update pakistan mobile regex according to suggestion Co-authored-by: Sarhan Aissi <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for making the necessary changes! LGTM 🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks for your contrib! 🎉
* Fix Mobile Phone Regex Pakistan(PK) Update the regex to validate mobile numbers correctly for Pakistan * Add tests for mobile number validation locale en-PK (Pakistan) * Linting fix * Update src/lib/isMobilePhone.js Update pakistan mobile regex according to suggestion Co-authored-by: Sarhan Aissi <[email protected]> * Update tests for PK phone numbers Co-authored-by: Sarhan Aissi <[email protected]>
* Fix Mobile Phone Regex Pakistan(PK) Update the regex to validate mobile numbers correctly for Pakistan * Add tests for mobile number validation locale en-PK (Pakistan) * Linting fix * Update src/lib/isMobilePhone.js Update pakistan mobile regex according to suggestion Co-authored-by: Sarhan Aissi <[email protected]> * Update tests for PK phone numbers Co-authored-by: Sarhan Aissi <[email protected]>
* Fix Mobile Phone Regex Pakistan(PK) Update the regex to validate mobile numbers correctly for Pakistan * Add tests for mobile number validation locale en-PK (Pakistan) * Linting fix * Update src/lib/isMobilePhone.js Update pakistan mobile regex according to suggestion Co-authored-by: Sarhan Aissi <[email protected]> * Update tests for PK phone numbers Co-authored-by: Sarhan Aissi <[email protected]>
Fixed the mobile phone regex for Pakistan.
Reference: 1, 2
Added tests for mobile phone, local en-PK (Pakistan)
Checklist