-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
chore: combined PR clean-up #2164
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
Changes from 5 commits
8604748
427b035
bde420b
5bb8c91
a310168
b489355
31a74d5
58f4b13
c6f2196
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -95,6 +95,7 @@ const phones = { | |||||
| 'fo-FO': /^(\+?298)?\s?\d{2}\s?\d{2}\s?\d{2}$/, | ||||||
| 'fr-BF': /^(\+226|0)[67]\d{7}$/, | ||||||
| 'fr-BJ': /^(\+229)\d{8}$/, | ||||||
| 'fr-CD': /^(\+?243|0)?(8|9)\d{8}$/, | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
According to https://www.itu.int/dms_pub/itu-t/oth/02/02/T02020000370001PDFE.pdf with the addition of Africell phone numbers from https://github.com/google/libphonenumber/blob/master/resources/metadata/243/ranges.csv in line with the comment of the creator of the original PR
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We can fix this in a later PR as well |
||||||
| 'fr-CM': /^(\+?237)6[0-9]{8}$/, | ||||||
| 'fr-FR': /^(\+?33|0)[67]\d{8}$/, | ||||||
| 'fr-GF': /^(\+?594|0|00594)[67]\d{8}$/, | ||||||
|
|
@@ -131,6 +132,7 @@ const phones = { | |||||
| 'pt-BR': /^((\+?55\ ?[1-9]{2}\ ?)|(\+?55\ ?\([1-9]{2}\)\ ?)|(0[1-9]{2}\ ?)|(\([1-9]{2}\)\ ?)|([1-9]{2}\ ?))((\d{4}\-?\d{4})|(9[1-9]{1}\d{3}\-?\d{4}))$/, | ||||||
| 'pt-PT': /^(\+?351)?9[1236]\d{7}$/, | ||||||
| 'pt-AO': /^(\+244)\d{9}$/, | ||||||
| 'ro-MD': /^(\+?373|0)((6(0|1|2|6|7|8|9))|(7(6|7|8|9)))\d{6}$/, | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
According to https://www.itu.int/dms_pub/itu-t/oth/02/02/T020200008C0003PDFE.pdf
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We can fix this in a later PR as well
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I totally agree... we can do a subsequent fix for that. |
||||||
| 'ro-RO': /^(\+?40|0)\s?7\d{2}(\/|\s|\.|-)?\d{3}(\s|\.|-)?\d{3}$/, | ||||||
| 'ru-RU': /^(\+?7|8)?9\d{9}$/, | ||||||
| 'si-LK': /^(?:0|94|\+94)?(7(0|1|2|4|5|6|7|8)( |-)?)\d{7}$/, | ||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -37,8 +37,11 @@ const passportRegexByCountryCode = { | |||||
| IR: /^[A-Z]\d{8}$/, // IRAN | ||||||
| IS: /^(A)\d{7}$/, // ICELAND | ||||||
| IT: /^[A-Z0-9]{2}\d{7}$/, // ITALY | ||||||
| JM: /^[Aa]\d{7}$/, // JAMAICA | ||||||
| JP: /^[A-Z]{2}\d{7}$/, // JAPAN | ||||||
| KR: /^[MS]\d{8}$/, // SOUTH KOREA, REPUBLIC OF KOREA, [S=PS Passports, M=PM Passports] | ||||||
| KZ: /^[a-zA-Z]\d{7}$/, // KAZAKHSTAN | ||||||
| LI: /^[a-zA-Z]\d{5}$/, // LIECHTENSTEIN | ||||||
| LT: /^[A-Z0-9]{8}$/, // LITHUANIA | ||||||
| LU: /^[A-Z0-9]{8}$/, // LUXEMBURG | ||||||
| LV: /^[A-Z0-9]{2}\d{7}$/, // LATVIA | ||||||
|
|
@@ -48,12 +51,13 @@ const passportRegexByCountryCode = { | |||||
| MY: /^[AHK]\d{8}$/, // MALAYSIA | ||||||
| MX: /^\d{10,11}$/, // MEXICO | ||||||
| NL: /^[A-Z]{2}[A-Z0-9]{6}\d$/, // NETHERLANDS | ||||||
| NZ: /^([Ll]([Aa]|[Dd]|[Ff]|[Hh])|[Ee]([Aa]|[Pp])|[Nn])\d{6}$/, // NEW ZELAND | ||||||
|
||||||
| NZ: /^([Ll]([Aa]|[Dd]|[Ff]|[Hh])|[Ee]([Aa]|[Pp])|[Nn])\d{6}$/, // NEW ZELAND | |
| NZ: /^([Ll]([Aa]|[Dd]|[Ff]|[Hh])|[Ee]([Aa]|[Pp])|[Nn])\d{6}$/, // NEW ZEALAND |
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.
good catch, fixed, thanks!
Uh oh!
There was an error while loading. Please reload this page.