Mercurial > libervia-web
changeset 377:603fa314880e
browser side: fixed bad variable reference in menus management
author | Goffi <goffi@goffi.org> |
---|---|
date | Tue, 25 Feb 2014 09:42:52 +0100 |
parents | ab923b870fb0 |
children | 3dd0b5334aef |
files | browser_side/menu.py |
diffstat | 1 files changed, 5 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/browser_side/menu.py Tue Feb 25 02:13:53 2014 +0100 +++ b/browser_side/menu.py Tue Feb 25 09:42:52 2014 +0100 @@ -179,12 +179,16 @@ if not path: print "WARNING: skipping menu without path" continue + if len(path) != len(path_i18n): + print "ERROR: inconsistency between menu paths" + continue menu_name = path[0] menu_name_i18n = path_i18n[0] - item_name_i18n = ' | '.join(path_i18n[1:]) + item_name = path[1:] if not item_name: print "WARNING: skipping menu with a path of lenght 1 [%s]" % path[0] continue + item_name_i18n = ' | '.join(path_i18n[1:]) addMenu(menu_name, menu_name_i18n, item_name_i18n, 'plugins', PluginMenuCmd(self.host, action_id)) menus_order.append(None) # we add separator