From 0024e89eee5890684c885b46751a44ae39eda68d Mon Sep 17 00:00:00 2001
From: Dalai Felinto <dfelinto@gmail.com>
Date: Thu, 24 May 2018 13:51:54 +0200
Subject: [PATCH] Fix STL exporter for 2.8

---
 io_mesh_stl/blender_utils.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/io_mesh_stl/blender_utils.py b/io_mesh_stl/blender_utils.py
index 864335ab9..d6ee400cb 100644
--- a/io_mesh_stl/blender_utils.py
+++ b/io_mesh_stl/blender_utils.py
@@ -84,7 +84,7 @@ def faces_from_mesh(ob, global_matrix, use_mesh_modifiers=False, triangulate=Tru
 
     # get the modifiers
     try:
-        mesh = ob.to_mesh(bpy.context.scene, use_mesh_modifiers, "PREVIEW")
+        mesh = ob.to_mesh(bpy.context.depsgraph, use_mesh_modifiers)
     except RuntimeError:
         raise StopIteration
 
-- 
GitLab