Skip to content

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