diff --git a/src/dom_components/model/Component.js b/src/dom_components/model/Component.js index f4f35bf7d..0b9f2afda 100644 --- a/src/dom_components/model/Component.js +++ b/src/dom_components/model/Component.js @@ -364,7 +364,7 @@ const Component = Backbone.Model.extend(Styleable).extend( classes.length && (attributes.class = classes.join(' ')); // If the rule is setted we need an ID attached to the component - if (!has(attributes, 'id') && sm.get(id, sm.Selector.TYPE_ID)) { + if (!has(attributes, 'id') && sm && sm.get(id, sm.Selector.TYPE_ID)) { attributes.id = this.getId(); } diff --git a/test/specs/style_manager/view/PropertySelectView.js b/test/specs/style_manager/view/PropertySelectView.js index f0417e867..d2d8a9bda 100644 --- a/test/specs/style_manager/view/PropertySelectView.js +++ b/test/specs/style_manager/view/PropertySelectView.js @@ -1,5 +1,5 @@ const PropertySelectView = require('style_manager/view/PropertySelectView'); -const Property = require('style_manager/model/Property'); +const Property = require('style_manager/model/PropertyRadio'); const Editor = require('editor/model/Editor'); const DomComponents = require('dom_components'); const Component = require('dom_components/model/Component');