diff options
Diffstat (limited to 'addons/web_editor/static/src')
| -rw-r--r-- | addons/web_editor/static/src/js/editor/snippets.options.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/addons/web_editor/static/src/js/editor/snippets.options.js b/addons/web_editor/static/src/js/editor/snippets.options.js index 621cd9b4d6f..841383c589d 100644 --- a/addons/web_editor/static/src/js/editor/snippets.options.js +++ b/addons/web_editor/static/src/js/editor/snippets.options.js @@ -3528,7 +3528,10 @@ registry.BackgroundOptimize = ImageHandlerOption.extend({ */ async _loadImageInfo() { this.img = new Image(); - Object.entries(this.$target[0].dataset).forEach(([key, value]) => { + Object.entries(this.$target[0].dataset).filter(([key]) => + // Avoid copying dynamic editor attributes + !['oeId','oeModel', 'oeField', 'oeXpath', 'noteId'].includes(key) + ).forEach(([key, value]) => { this.img.dataset[key] = value; }); const src = getBgImageURL(this.$target[0]); |
