fix menu bug

This commit is contained in:
ivan deng
2023-05-04 17:43:44 +08:00
parent 6b89a5cfa1
commit b18cac946e
3 changed files with 4 additions and 2 deletions

View File

@@ -46,7 +46,7 @@ patch(UserMenu.prototype, "app_odoo_customize.UserMenu", {
}
if (session.app_show_account) {
userMenuRegistry.add("odoo_account", odooAccountItem, {'force': true});
} else if (userMenuRegistry.get('odoo_account')){
} else if (userMenuRegistry.get('odoo_account', false)){
try {
userMenuRegistry.remove("odoo_account");
} catch (err) {