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

Not correctly removing all branch descendants on reset #52

Closed
oliverfoster opened this issue Apr 10, 2024 · 1 comment · Fixed by #53
Closed

Not correctly removing all branch descendants on reset #52

oliverfoster opened this issue Apr 10, 2024 · 1 comment · Fixed by #53
Assignees
Labels
bug Something isn't working released

Comments

@oliverfoster
Copy link
Member

Subject of the issue

branchedModels.forEach(model => {
if (Adapt.parentView && removeViews) {
const view = data.findViewByModelId(model.get('_id'));
if (view) {
view.remove();
childViews.splice(childViews.findIndex(v => v === view), 1);
parentView.nthChild--;
}
}
data.remove(model);
});

branchedModels are only the immediate blocks, their children when cloned had also been added to Adapt.data and need to be likewise removed.

Copy link

🎉 This issue has been resolved in version 1.2.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant