diff --git a/addons/web/__manifest__.py b/addons/web/__manifest__.py index d4dea87752c..7015f7cebcf 100644 --- a/addons/web/__manifest__.py +++ b/addons/web/__manifest__.py @@ -123,6 +123,7 @@ This module provides the core of the Odoo Web Client. 'web/static/src/start.js', ], 'web.assets_frontend_minimal': [ + 'web/static/src/polyfills/object.js', 'web/static/src/module_loader.js', 'web/static/src/session.js', 'web/static/src/core/browser/cookie.js', diff --git a/addons/web/static/src/polyfills/object.js b/addons/web/static/src/polyfills/object.js new file mode 100644 index 00000000000..a8f0790fe28 --- /dev/null +++ b/addons/web/static/src/polyfills/object.js @@ -0,0 +1,3 @@ +if (!Object.hasOwn) { + Object.hasOwn = (obj, key) => Object.prototype.hasOwnProperty.call(obj, key); +}