Skip to content

Commit

Permalink
fix(document): only skip modifying subdoc path if parent is direct mo…
Browse files Browse the repository at this point in the history
…dified

Fix #4405
  • Loading branch information
vkarpov15 committed Aug 18, 2016
1 parent 0a66821 commit 0ccf493
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/types/subdocument.js
Expand Up @@ -46,7 +46,7 @@ Subdocument.prototype.$isValid = function(path) {
Subdocument.prototype.markModified = function(path) {
Document.prototype.markModified.call(this, path);
if (this.$parent) {
if (this.$parent.isModified(this.$basePath)) {
if (this.$parent.isDirectModified(this.$basePath)) {
return;
}
this.$parent.markModified([this.$basePath, path].join('.'));
Expand Down

0 comments on commit 0ccf493

Please sign in to comment.