Skip to content

Commit

Permalink
Updates from the previous merge
Browse files Browse the repository at this point in the history
  • Loading branch information
chriso committed Jan 30, 2018
1 parent ca20e91 commit f2b9806
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

- Added an option to `isMobilePhone` to require a country code
([#769](https://github.com/chriso/validator.js/pull/769))
- New and improved locales
([#785](https://github.com/chriso/validator.js/pull/785))

#### 9.3.0

Expand Down
4 changes: 2 additions & 2 deletions lib/isMobilePhone.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ var phones = {
'en-AU': /^(\+?61|0)4\d{8}$/,
'en-GB': /^(\+?44|0)7\d{9}$/,
'en-HK': /^(\+?852\-?)?[456789]\d{3}\-?\d{4}$/,
'en-IN': /^(\+?91|0)?[6789]\d{9}$/,
'en-IN': /^(\+?91|0)?[789]\d{9}$/,
'en-KE': /^(\+?254|0)?[7]\d{8}$/,
'en-NG': /^(\+?234|0)?[789]\d{9}$/,
'en-NZ': /^(\+?64|0)2\d{7,9}$/,
Expand Down Expand Up @@ -100,4 +100,4 @@ function isMobilePhone(str, locale, options) {
}
throw new Error('Invalid locale \'' + locale + '\'');
}
module.exports = exports['default'];
module.exports = exports['default'];

5 comments on commit f2b9806

@geekguy
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@chriso - this commit reverses changes made in the previous commit. Is that intentional?

@chriso
Copy link
Collaborator Author

@chriso chriso commented on f2b9806 Jan 30, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah whoops, I'll fix that up. You updated the compiled version lib/isMobilePhone.js rather than the source src/lib/isMobilePhone.js and so compiling it locally reversed the change.

@geekguy
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Er. My bad. Should I raise another PR?

@chriso
Copy link
Collaborator Author

@chriso chriso commented on f2b9806 Jan 30, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See 4fb34e9

@geekguy
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool. Thanks.

Please sign in to comment.