-
-
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
Update '"zh-CN"' #1178
Update '"zh-CN"' #1178
Conversation
The prefix '+' and '00' of 'zh-CN' are not required
src/lib/isMobilePhone.js
Outdated
@@ -83,7 +83,7 @@ const phones = { | |||
'tr-TR': /^(\+?90|0)?5\d{9}$/, | |||
'uk-UA': /^(\+?38|8)?0\d{9}$/, | |||
'vi-VN': /^(\+?84|0)((3([2-9]))|(5([2689]))|(7([0|6-9]))|(8([1-6|89]))|(9([0-9])))([0-9]{7})$/, | |||
'zh-CN': /^((\+|00)86)?1([358][0-9]|4[579]|6[67]|7[0135678]|9[189])[0-9]{8}$/, | |||
'zh-CN': /^((\+|00)?86)?1([358][0-9]|4[579]|6[67]|7[0135678]|9[189])[0-9]{8}$/, |
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.
I think this will also need some tests added.
Cc. @tux-tn and @profnandaa.
@liuzhaowei55, how does this PR differ with this one #1174? |
His PR is good, starting with "+86172" number is mobile number. |
So, does this mean that you have done what has already been done? Cc. @profnandaa and @tux-tn. |
e.g: |
…into validatorjs-master # Conflicts: # src/lib/isMobilePhone.js # test/validators.js
The prefix '+' and '00' of 'zh-CN' are not required