Skip to content

Commit

Permalink
fix(document): handle errors in subdoc pre validate
Browse files Browse the repository at this point in the history
Fix #5215
  • Loading branch information
vkarpov15 committed May 9, 2017
1 parent 9f24e99 commit eed8bcd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/schema/embedded.js
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ Embedded.prototype.doValidate = function(value, fn, scope) {
if (!(value instanceof Constructor)) {
value = new Constructor(value);
}
value.validate(fn, {__noPromise: true});
value.validate({__noPromise: true}, fn);
}, scope);
};

Expand Down

0 comments on commit eed8bcd

Please sign in to comment.