diff --git a/CHANGELOG.md b/CHANGELOG.md index a374072b..a704801e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - bug fixes - patchbay: layout issue + - widget: regression causing error when emptying the css property ## 1.27.4 diff --git a/src/client/widgets/common/widget.js b/src/client/widgets/common/widget.js index fe629c84..4b97f478 100644 --- a/src/client/widgets/common/widget.js +++ b/src/client/widgets/common/widget.js @@ -1201,7 +1201,7 @@ class Widget extends EventEmitter { var style = (unScopedCss ? prefix + '{' + unScopedCss + '}\n' : '') + scopedCss style = style.trim() - if (this.style) { + if (this.style && this.container.contains(this.style)) { if (style) this.style.innerText = style else this.container.removeChild(this.style) } else if (scopedCss.length || unScopedCss.length){