Skip to content

Commit aacbbe8

Browse files
committed
Turns out the xmldom lib handles the cases we tried to handle when setting attribute NS
1 parent 5db907d commit aacbbe8

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

src/XmlWriter.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,6 @@ class XmlWriter{
2525
doc.insertBefore(doc.createProcessingInstruction('xml', 'version="1.0" encoding="utf-8"'), doc.documentElement)
2626
let documentElement = doc.documentElement
2727

28-
if(namespaceURI && namespace){
29-
documentElement.setAttributeNS(namespaceURI, 'xmlns', namespace)
30-
}
31-
if(namespaceURI){
32-
documentElement.setAttributeNS(namespaceURI, 'xmlns:xsi', namespaceURI)
33-
}
3428
if(namespaceURI && schemaLocation){
3529
documentElement.setAttributeNS(namespaceURI, 'xsi:schemaLocation', schemaLocation)
3630
}

0 commit comments

Comments
 (0)