We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 755fa81 commit 88f53f7Copy full SHA for 88f53f7
1 file changed
src/blenderbim/blenderbim/bim/module/material/operator.py
@@ -250,7 +250,8 @@ def _execute(self, context):
250
if element:
251
material = ifcopenshell.util.element.get_material(element, should_inherit=False)
252
inherited_material = ifcopenshell.util.element.get_material(element, should_inherit=True)
253
- if "Usage" in material.is_a():
+ print(material, inherited_material)
254
+ if material and "Usage" in material.is_a():
255
element_type = ifcopenshell.util.element.get_type(element)
256
ifcopenshell.api.run("material.unassign_material", tool.Ifc.get(), product=element_type)
257
elif not material and inherited_material:
0 commit comments