Skip to content

Commit 171a20f

Browse files
committed
[xmlparser.py] ignore_errors: Change Object Initialization
From Null to current type (Document, Section, Property). Related to issue #276.
1 parent 09fcb09 commit 171a20f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

odml/tools/xmlparser.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
# this is needed for py2exe to include lxml completely
1212
from lxml import _elementpath as _dummy
1313
from os.path import basename
14+
import uuid
1415

1516
try:
1617
from StringIO import StringIO
@@ -310,8 +311,7 @@ def parse_tag(self, root, fmt, insert_children=True):
310311
self.check_mandatory_arguments(check_args, fmt, root.tag, root)
311312

312313
# Instantiate the current odML object with the parsed attributes.
313-
# Return None, if
314-
obj = None
314+
obj = fmt.create()
315315
try:
316316
obj = fmt.create(**arguments)
317317
except Exception as e:

0 commit comments

Comments
 (0)