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

Minor refactor to ValidationError #8244

Merged
merged 2 commits into from
Oct 14, 2019
Merged

Conversation

AbdelrahmanHafez
Copy link
Collaborator

Minor refactor to the ValidationError constructor, took a duplicated line out of both conditions.

Copy link
Collaborator

@vkarpov15 vkarpov15 left a comment

Choose a reason for hiding this comment

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

Thanks! I made a minor change because the this.name = 'ValidationError' line needs to be after MongooseError.call(), because MongooseError.call() sets this.name too.

@vkarpov15 vkarpov15 added this to the 5.7.5 milestone Oct 14, 2019
@vkarpov15 vkarpov15 added the refactor This is a purely internal change for making Mongoose internals easier to understand and work with label Oct 14, 2019
@vkarpov15 vkarpov15 merged commit e6285ea into Automattic:master Oct 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactor This is a purely internal change for making Mongoose internals easier to understand and work with
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants