From 0f4e8df0e1441d8923dc0aaf24d45346efe862e9 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Tue, 17 Dec 2024 15:08:23 +0000 Subject: [PATCH] [FIX] test_themes: restore the website switcher The forward-port of [1] made no adaptation to the code, and it now simply crashes when trying to use the website switcher when test_themes is installed. This also fixes a linter error introduced by that same [1] commit. [1]: https://github.com/odoo/design-themes/commit/c3af5d9796929025c9503ab639afc8c60a262b3f closes odoo/design-themes#1037 X-original-commit: a5a838e84fb8ab17aa2856f5e866a1107d9ca1a5 Related: odoo/odoo#191567 Signed-off-by: Quentin Smetz (qsm) --- test_themes/static/src/systray_items/website_switcher.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test_themes/static/src/systray_items/website_switcher.js b/test_themes/static/src/systray_items/website_switcher.js index fd716cfef..b112dd28b 100644 --- a/test_themes/static/src/systray_items/website_switcher.js +++ b/test_themes/static/src/systray_items/website_switcher.js @@ -29,13 +29,13 @@ patch(WebsiteSwitcherSystray.prototype, { getElements() { // Add tooltip information - const elements = this._super(); + const elements = super.getElements(...arguments); return elements.map((elem) => { elem.dataset = { ...elem.dataset, ...this.tooltips[elem.id] }; - return elem + return elem; }); },