From fc6dfc7995cb13e96508d1462e993c609d7f037c Mon Sep 17 00:00:00 2001 From: Yeicor <4929005+Yeicor@users.noreply.github.com> Date: Fri, 1 Dec 2023 21:11:07 +0100 Subject: [PATCH] Fix export code for boot case --- main.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 506a06c..5c66a5a 100644 --- a/main.py +++ b/main.py @@ -36,4 +36,7 @@ print("Cannot show model, exporting to STL instead (%s)" % ex) if export: - obj.part.export_stl('boot-protector.stl') + if hasattr(obj, 'part'): + obj.part.export_stl('boot-protector.stl') + else: + export_stl(obj, 'boot-protector.stl')