See #3974. WIP review to ensure history removal in API.

This commit is contained in:
Dion Moult
2023-11-27 18:31:42 +11:00
parent f215670381
commit 14f1acadb7
22 changed files with 174 additions and 5 deletions
@@ -16,7 +16,8 @@
# You should have received a copy of the GNU Lesser General Public License
# along with IfcOpenShell. If not, see <http://www.gnu.org/licenses/>.
import ifcopenshell.api
import ifcopenshell
import ifcopenshell.util.element
class Usecase:
@@ -48,4 +49,7 @@ class Usecase:
self.settings = {"actor": actor}
def execute(self):
history = self.settings["actor"].OwnerHistory
self.file.remove(self.settings["actor"])
if history:
ifcopenshell.util.element.remove_deep2(self.file, history)