diff --git a/fix_tei.py b/fix_tei.py index 5b8a85c..29f5039 100644 --- a/fix_tei.py +++ b/fix_tei.py @@ -332,6 +332,10 @@ def cleanup_xml(xml_tree): for paragraph in paragraphs: paragraph.attrib.pop("rend") + wrongblockquotes = xml_tree.xpath("//t:p[contains(@rend, 'Quotation')]", namespaces=NS_MAP) + for blockquote in wrongblockquotes: + paragraph.set("rend", "quote") + etree.strip_tags(xml_tree, "tagtobestripped") return xml_tree