diff options
Diffstat (limited to 'addons/web_editor/static/src/js/transcoder.js')
| -rw-r--r-- | addons/web_editor/static/src/js/transcoder.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/addons/web_editor/static/src/js/transcoder.js b/addons/web_editor/static/src/js/transcoder.js index 9188bfabb45..6e0097ee8fb 100644 --- a/addons/web_editor/static/src/js/transcoder.js +++ b/addons/web_editor/static/src/js/transcoder.js @@ -137,6 +137,7 @@ var style_to_class = function ($editable) { $editable.find("[class]").each(function () { classes = classes.concat(this.className.split(/\s+/)); }); + classes = _.compact(classes); var maybe_selector = _.filter(rulesCache, function (a) { return !!_.find(classes, function (b) { return a.selector.indexOf("."+b) !== -1; } ); }); var selector = _.map(maybe_selector, function (a) { return a.selector;}).join(","); |
