projects
/
python
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8999053
)
Fixed bug that disallowed processing instructions before and after
author
Paul Prescod
<prescod@prescod.net>
Fri, 15 Sep 2000 17:09:19 +0000
(17:09 +0000)
committer
Paul Prescod
<prescod@prescod.net>
Fri, 15 Sep 2000 17:09:19 +0000
(17:09 +0000)
document element.
Lib/xml/dom/minidom.py
patch
|
blob
|
history
diff --git
a/Lib/xml/dom/minidom.py
b/Lib/xml/dom/minidom.py
index 3f5668ed7787e093dc2dfaeaae2acdf78d7dc991..18d82eed6f1b67f30f22d7712b4a105b542f0f32 100644
(file)
--- a/
Lib/xml/dom/minidom.py
+++ b/
Lib/xml/dom/minidom.py
@@
-396,10
+396,11
@@
class Document( Node ):
self.nodeValue=None
def appendChild( self, node ):
- if node.nodeType==Node.ELEMENT_NODE and self.documentElement:
- raise TypeError, "Two document elements disallowed"
- else:
- self.documentElement=node
+ if node.nodeType==Node.ELEMENT_NODE:
+ if self.documentElement:
+ raise TypeError, "Two document elements disallowed"
+ else:
+ self.documentElement=node
Node.appendChild( self, node )
return node