diff --git a/l10n_fr_intrastat_service/models/intrastat_service.py b/l10n_fr_intrastat_service/models/intrastat_service.py index a57278048..587e9b1c6 100644 --- a/l10n_fr_intrastat_service/models/intrastat_service.py +++ b/l10n_fr_intrastat_service/models/intrastat_service.py @@ -333,8 +333,7 @@ def generate_xml(self): if not self.declaration_line_ids: return root = self._generate_des_xml_root() - objectify.deannotate(root, xsi_nil=True) - etree.cleanup_namespaces(root) + objectify.deannotate(root, xsi_nil=True, cleanup_namespaces=True) xml_bytes = etree.tostring( root, pretty_print=True, encoding="UTF-8", xml_declaration=True )