#1433694: minidom's .normalize() failed to set .nextSibling for last element.

Fix by Malte Helmert
This commit is contained in:
Andrew M. Kuchling 2008-02-23 17:10:46 +00:00
parent 8887e54867
commit 19aff0c90a
3 changed files with 11 additions and 0 deletions

View file

@ -203,6 +203,8 @@ class Node(xml.dom.Node):
L.append(child)
if child.nodeType == Node.ELEMENT_NODE:
child.normalize()
if L:
L[-1].nextSibling = None
self.childNodes[:] = L
def cloneNode(self, deep):