Skip to content

Commit bac683e

Browse files
committed
Fix bug for getting psets of materials and profiles in IFC2X3
1 parent 840818d commit bac683e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • src/ifcopenshell-python/ifcopenshell/util

src/ifcopenshell-python/ifcopenshell/util/element.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def get_psets(element, psets_only=False, qtos_only=False, should_inherit=True):
121121
continue
122122
psets[definition.Name] = get_property_definition(definition)
123123
elif element.is_a("IfcMaterialDefinition") or element.is_a("IfcProfileDef"):
124-
for definition in element.HasProperties or []:
124+
for definition in getattr(element, "HasProperties", None) or []:
125125
if qtos_only:
126126
continue
127127
psets[definition.Name] = get_property_definition(definition)

0 commit comments

Comments
 (0)