Skip to content
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

feat: Added name to validation-error #60

Merged
merged 2 commits into from
May 12, 2019
Merged

Conversation

derpoho
Copy link
Contributor

@derpoho derpoho commented Mar 19, 2017

Some other express middleware is using error names to be able to discovered, just for the sake of having everything i would add this.

You can then check instead of err instanceof validate.ValidationError with err.name === 'ValidationError'

Some other express middleware is using error names to be able to discovered, just for the sake of having everything i would add this.

You can then check instead of `err instanceof validate.ValidationError`  with `err.name === 'ValidationError'`
@isaachinman
Copy link

Relevant docs here.

@isaachinman isaachinman changed the title Added name to validation-error feat: Added name to validation-error May 12, 2019
@isaachinman isaachinman merged commit 839c1c1 into AndrewKeig:master May 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants