From cc744d1b12d3ba396e97a8947872e9fb261241dc Mon Sep 17 00:00:00 2001 From: "Hubert Van de Walle (huvw)" Date: Mon, 30 Aug 2021 07:23:24 +0000 Subject: [PATCH] [FIX] web: prevent error if subscriptions.update is undefined Steps to follow - Install web_dashboard,website_sale - Go to the eCommerce Dashboard - Click on Favorites - Click on Add to my dashboard - Go to the Dashboard app - Click on orders -> A traceback occurs Cause of the issue `this.subscriptions.update` is undefined opw-2630849 closes odoo/odoo#75984 X-original-commit: 8ab700fc8e51631663443b6c8e81db9669375d82 Signed-off-by: Hubert Van De Walle --- addons/web/static/src/legacy/js/model.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/legacy/js/model.js b/addons/web/static/src/legacy/js/model.js index 4f3f13a44cf..a367706ea4c 100644 --- a/addons/web/static/src/legacy/js/model.js +++ b/addons/web/static/src/legacy/js/model.js @@ -429,7 +429,7 @@ odoo.define("web.Model", function (require) { */ async _notifyComponents() { const rev = ++this.rev; - const subscriptions = this.subscriptions.update; + const subscriptions = this.subscriptions.update || []; const groups = partitionBy(subscriptions, (s) => s.owner ? s.owner.__owl__.depth : -1 );