Browse Source

Merge pull request #2994 from jcamejo/remove-children-validation Fixes #2940

Remove children validation
pull/3024/head
Artur Arseniev 6 years ago
committed by GitHub
parent
commit
e56f35eb73
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      src/dom_components/model/Components.js

8
src/dom_components/model/Components.js

@ -22,11 +22,17 @@ export default Backbone.Collection.extend({
},
removeChildren(removed, coll, opts = {}) {
// Removing a parent component can cause this function
// to be called with an already removed child element
if (!removed) {
return;
}
const { domc, em } = this;
const allByID = domc ? domc.allById() : {};
if (!opts.temporary) {
// Remove the component from the gloabl list
// Remove the component from the global list
const id = removed.getId();
const sels = em.get('SelectorManager').getAll();
const rules = em.get('CssComposer').getAll();

Loading…
Cancel
Save