Use root prefix to retrieve the namespace of UBL document

Closes #14490
This commit is contained in:
Cédric Krier
2026-01-14 14:39:08 +01:00
parent 1623885d46
commit 91c5a087fb
+1 -1
View File
@@ -200,7 +200,7 @@ class Invoice(Model):
tree = etree.parse(BytesIO(document))
root = tree.getroot()
namespace = root.nsmap.get(None)
namespace = root.nsmap.get(root.prefix)
invoice, attachments = cls.parser(namespace)(root)
invoice.save()
invoice.update_taxes()