diff --git a/io_mesh_ply/export_ply.py b/io_mesh_ply/export_ply.py index eab74ca892a6b1f9067432b1518907a185a04791..48d1542f886caa5ebf3fb17443cb0984f8c3cbd5 100644 --- a/io_mesh_ply/export_ply.py +++ b/io_mesh_ply/export_ply.py @@ -190,7 +190,7 @@ def save(operator, use_uv_coords=True, use_colors=True, ): - + scene = context.scene obj = context.active_object @@ -199,7 +199,7 @@ def save(operator, obj.update_from_editmode() - if use_mesh_modifiers: + if use_mesh_modifiers and obj.modifiers: mesh = obj.to_mesh(scene, True, 'PREVIEW') else: mesh = obj.data.copy() @@ -220,4 +220,4 @@ def save(operator, if use_mesh_modifiers: bpy.data.meshes.remove(mesh) - return ret \ No newline at end of file + return ret