Commit 9b37d2e1 authored by Jérome Perrin's avatar Jérome Perrin

OOoTemplate: use simpler xpath expression

parent a6dd6619
......@@ -421,7 +421,7 @@ class OOoTemplate(ZopePageTemplate):
return replacement
xml_doc = etree.XML(text)
for office_include in xml_doc.xpath('//*[name() = "office:include"]'):
for office_include in xml_doc.xpath('//office:include', namespaces=xml_doc.nsmap):
marshal_list = office_include.xpath('./marshal')
if marshal_list:
from xml.marshal.generic import loads
......
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