Skip to content

Commit

Permalink
Merge pull request #1550 from heylookalive/master
Browse files Browse the repository at this point in the history
Highlight the minDomainAtoms option for the email validation method in readme
  • Loading branch information
Marsup committed Jul 30, 2018
2 parents 63492d4 + cf71883 commit 02dc91a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Expand Up @@ -28,7 +28,7 @@ const schema = Joi.object().keys({
password: Joi.string().regex(/^[a-zA-Z0-9]{3,30}$/),
access_token: [Joi.string(), Joi.number()],
birthyear: Joi.number().integer().min(1900).max(2013),
email: Joi.string().email()
email: Joi.string().email({ minDomainAtoms: 2 })
}).with('username', 'birthyear').without('password', 'access_token');

// Return result.
Expand Down Expand Up @@ -56,6 +56,7 @@ The above schema defines the following constraints:
* an integer between 1900 and 2013
* `email`
* a valid email address string
* must have two domain parts e.g. `example.com`

# Usage

Expand Down

3 comments on commit 02dc91a

@papandreou
Copy link

Choose a reason for hiding this comment

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

@Marsup, there doesn't seem to be a v13.5.1 tag here. Did you to push it along with the release commit?

@Marsup
Copy link
Collaborator Author

@Marsup Marsup commented on 02dc91a Jul 30, 2018

Choose a reason for hiding this comment

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

@papandreou fixed. It contained nothing.

@papandreou
Copy link

Choose a reason for hiding this comment

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

Thanks :)

Please sign in to comment.