diff --git a/src/bonsai/bonsai/bim/export_ifc.py b/src/bonsai/bonsai/bim/export_ifc.py index 8b010fd141..7f2ec42188 100644 --- a/src/bonsai/bonsai/bim/export_ifc.py +++ b/src/bonsai/bonsai/bim/export_ifc.py @@ -47,7 +47,6 @@ class IfcExporter: self.set_header() IfcStore.update_cache() self.sync_all_objects() - self.sync_edited_objects() tool.Project.save_linked_models_to_ifc() extension = self.ifc_export_settings.output_file.split(".")[-1].lower() if extension == "ifczip": @@ -110,20 +109,6 @@ class IfcExporter: pass # The object is likely deleted return results - def sync_edited_objects(self) -> list[ifcopenshell.entity_instance]: - results: list[ifcopenshell.entity_instance] = [] - for obj in IfcStore.edited_objs.copy(): - if not obj: - continue - if not tool.Blender.is_valid_data_block(obj): - continue - element = tool.Ifc.get_entity(obj) - if element: - results.append(element) - bpy.ops.bim.update_representation(obj=obj.name) - IfcStore.edited_objs.clear() - return results - def sync_object_material(self, obj: bpy.types.Object) -> None: if not obj.data or not isinstance(obj.data, bpy.types.Mesh): return diff --git a/src/bonsai/bonsai/bim/module/drawing/operator.py b/src/bonsai/bonsai/bim/module/drawing/operator.py index 702711dc1e..71fd2ec299 100644 --- a/src/bonsai/bonsai/bim/module/drawing/operator.py +++ b/src/bonsai/bonsai/bim/module/drawing/operator.py @@ -799,7 +799,6 @@ class CreateDrawing(bpy.types.Operator): exporter = bonsai.bim.export_ifc.IfcExporter(None) exporter.file = tool.Ifc.get() invalidated_elements = exporter.sync_all_objects() - invalidated_elements += exporter.sync_edited_objects() invalidated_guids = [e.GlobalId for e in invalidated_elements if hasattr(e, "GlobalId")] if cache := IfcStore.get_cache(): [cache.remove(guid) for guid in invalidated_guids]