mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-10 01:41:57 +00:00
Removing a property set now also removes properties
This commit is contained in:
@@ -37,7 +37,12 @@ class Usecase:
|
||||
inverse.RelatedObjects = related_objects
|
||||
should_remove_pset = False
|
||||
if should_remove_pset:
|
||||
if self.settings["pset"].is_a("IfcPropertySet"):
|
||||
properties = self.settings["pset"].HasProperties or []
|
||||
elif self.settings["pset"].is_a("IfcQuantitySet"):
|
||||
properties = self.settings["pset"].Quantities or []
|
||||
for prop in properties:
|
||||
self.file.remove(prop)
|
||||
self.file.remove(self.settings["pset"])
|
||||
for element in to_purge:
|
||||
self.file.remove(element)
|
||||
# TODO: implement deep purging
|
||||
|
||||
Reference in New Issue
Block a user