Commit 0c03fab7 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

xml.find('language') returns None because 'language' is the root element in this xml.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@33133 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 2750c883
......@@ -4530,9 +4530,8 @@ class MessageTranslationTemplateItem(BaseTemplateItem):
self._objects[file_name[:-3]] = text
elif name == 'language.xml':
xml = parse(file)
language_element = xml.find('language')
name = language_element.find('name').text
code = language_element.find('code').text
name = xml.find('name').text
code = xml.find('code').text
self._objects[code] = name
class LocalRolesTemplateItem(BaseTemplateItem):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment