mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-10 01:41:57 +00:00
Fix bug where element replacement would sometimes fail leading to various problems.
This commit is contained in:
@@ -97,7 +97,9 @@ def replace_attribute(element, old, new):
|
||||
def has_element_reference(value, element):
|
||||
if isinstance(value, (tuple, list)):
|
||||
for v in value:
|
||||
return has_element_reference(v, element)
|
||||
if has_element_reference(v, element):
|
||||
return True
|
||||
return False
|
||||
return value == element
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user