Skip to content

Commit

Permalink
feat(isMobilePhone): add support for ar-EG 015 (validatorjs#1010)
Browse files Browse the repository at this point in the history
feat(isMobilePhone): add support for ar-EG 015
  • Loading branch information
AMRALAA10 authored and profnandaa committed Apr 11, 2019
1 parent c51f92e commit 2c68a31
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/isMobilePhone.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import assertString from './util/assertString';
const phones = {
'ar-AE': /^((\+?971)|0)?5[024568]\d{7}$/,
'ar-DZ': /^(\+?213|0)(5|6|7)\d{8}$/,
'ar-EG': /^((\+?20)|0)?1[012]\d{8}$/,
'ar-EG': /^((\+?20)|0)?1[0125]\d{8}$/,
'ar-IQ': /^(\+?964|0)?7[0-9]\d{8}$/,
'ar-JO': /^(\+?962|0)?7[789]\d{7}$/,
'ar-KW': /^(\+?965)[569]\d{7}$/,
Expand Down
4 changes: 4 additions & 0 deletions test/validators.js
Original file line number Diff line number Diff line change
Expand Up @@ -3380,8 +3380,12 @@ describe('Validators', () => {
'+201274652177',
'+201280134679',
'+201090124576',
'+201583728900',
'201599495596',
'201090124576',
'01090124576',
'01538920744',
'1593075993',
'1090124576',
],
invalid: [
Expand Down

0 comments on commit 2c68a31

Please sign in to comment.