Skip to content

Commit

Permalink
quick fix
Browse files Browse the repository at this point in the history
  • Loading branch information
vkarpov15 committed Feb 13, 2025
1 parent 29a02a4 commit 9bb9ce7
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions lib/document.js
Original file line number Diff line number Diff line change
Expand Up @@ -3540,9 +3540,6 @@ Document.prototype.$__reset = function reset() {
*/

Document.prototype.$__undoReset = function $__undoReset() {
if (this.$isSubdocument) {
return;
}
if (this.$__.backup == null || this.$__.backup.activePaths == null) {
return;
}
Expand All @@ -3561,8 +3558,10 @@ Document.prototype.$__undoReset = function $__undoReset() {
}
}

for (const subdoc of this.$getAllSubdocs()) {
subdoc.$__undoReset();
if (!this.$isSubdocument) {
for (const subdoc of this.$getAllSubdocs()) {
subdoc.$__undoReset();
}
}
};

Expand Down

0 comments on commit 9bb9ce7

Please sign in to comment.