def cleanup_namespaces(element):
if etree.__name__ == '<STR_LIT>':<EOL><INDENT>etree.cleanup_namespaces(element)<EOL>return element<EOL><DEDENT>else:<EOL><INDENT>return etree.fromstring(etree.tostring(element))<EOL><DEDENT>
Remove unused namespaces from an element