mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-16 21:42:19 +00:00
Fix ids.from_string always breaking on validation (4a9cf43)
Since `tree` is never provided.
This commit is contained in:
@@ -63,6 +63,7 @@ def open(filepath: str, validate: bool = False) -> Ids:
|
|||||||
|
|
||||||
|
|
||||||
def from_string(xml: str, validate: bool = False) -> Ids:
|
def from_string(xml: str, validate: bool = False) -> Ids:
|
||||||
|
tree = ET.ElementTree(ET.fromstring(xml))
|
||||||
try:
|
try:
|
||||||
if validate:
|
if validate:
|
||||||
get_schema().validate(tree)
|
get_schema().validate(tree)
|
||||||
|
|||||||
Reference in New Issue
Block a user