diff --git a/src/blenderbim/blenderbim/bim/helper.py b/src/blenderbim/blenderbim/bim/helper.py index 29bb267932..8b7dfc6c1d 100644 --- a/src/blenderbim/blenderbim/bim/helper.py +++ b/src/blenderbim/blenderbim/bim/helper.py @@ -53,7 +53,7 @@ def draw_attribute(attribute, layout, copy_operator=None): def import_attributes(ifc_class, props, data, callback=None): for attribute in IfcStore.get_schema().declaration_by_name(ifc_class).all_attributes(): data_type = ifcopenshell.util.attribute.get_primitive_type(attribute) - if data_type == "entity" or (isinstance(data_type, tuple) and "entity" in ".".join(data_type)): + if isinstance(data_type, tuple) or data_type == "entity": callback(attribute.name(), None, data) if callback else None continue new = props.add() diff --git a/src/ifcopenshell-python/ifcopenshell/util/attribute.py b/src/ifcopenshell-python/ifcopenshell/util/attribute.py index 5e56c62f2f..e874dff672 100644 --- a/src/ifcopenshell-python/ifcopenshell/util/attribute.py +++ b/src/ifcopenshell-python/ifcopenshell/util/attribute.py @@ -3,10 +3,12 @@ def get_primitive_type(attribute_or_data_type): data_type = str(attribute_or_data_type.type_of_attribute()) else: data_type = str(attribute_or_data_type) - if "" in data_type: