mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Fix #3432. Bug where null applicable occurrence of a type product caused the annotation tool to fail.
This commit is contained in:
@@ -151,7 +151,11 @@ class Drawing(blenderbim.core.tool.Drawing):
|
||||
if element_type == "IfcAnnotation" and element.ObjectType in object_types:
|
||||
return True
|
||||
|
||||
if element_type == "IfcTypeProduct" and element.ApplicableOccurrence.startswith("IfcAnnotation/"):
|
||||
if (
|
||||
element_type == "IfcTypeProduct"
|
||||
and element.ApplicableOccurrence
|
||||
and element.ApplicableOccurrence.startswith("IfcAnnotation/")
|
||||
):
|
||||
applicable_object_type = element.ApplicableOccurrence.split("/")[1]
|
||||
if applicable_object_type in object_types:
|
||||
return True
|
||||
|
||||
Reference in New Issue
Block a user