[FIX] QWeb: omit non elements when searching for template declaration

bzr revid: fme@openerp.com-20130821094535-9gnpix2wu5zmncnc
This commit is contained in:
Fabien Meghazi 2013-08-21 11:45:35 +02:00
parent 346b9c2102
commit 4a4169ba75
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ class QWebXml(object):
else:
dom = xml.dom.minidom.parse(x)
for n in dom.documentElement.childNodes:
if n.getAttribute('t-name'):
if n.nodeType == 1 and n.getAttribute('t-name'):
self._t[str(n.getAttribute("t-name"))] = n
def get_template(self, name):