Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikhail Rachinskiy <mikhail.rachinskiy@gmail.com>2019-10-13 16:21:50 +0300
committerMikhail Rachinskiy <mikhail.rachinskiy@gmail.com>2019-10-13 16:21:50 +0300
commitb60a0302f5d3eb9a371ffd59645fc1a5bec49e83 (patch)
tree1fa040aed1e459d3475618c4039de2a223ae1c51 /object_print3d_utils
parent16b4498b6899ec23923235288218fea0dcb2ea15 (diff)
3D-Print: cleanup redundant code
already unlinks and removes object.
Diffstat (limited to 'object_print3d_utils')
-rw-r--r--object_print3d_utils/export.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/object_print3d_utils/export.py b/object_print3d_utils/export.py
index a294512b..d1359ecf 100644
--- a/object_print3d_utils/export.py
+++ b/object_print3d_utils/export.py
@@ -177,11 +177,7 @@ def write_mesh(context, report_cb):
image_copy_guess(filepath, context_override["selected_objects"])
if obj_tmp is not None:
- obj = obj_tmp
- mesh = obj.data
- collection.objects.unlink(obj)
- bpy.data.objects.remove(obj)
- bpy.data.meshes.remove(mesh)
+ bpy.data.meshes.remove(obj_tmp.data) # Automatically unlinks and removes object
# restore context
for ob in context_backup["selected_objects"]: