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

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Paschal <ianpaschal@users.noreply.github.com>2018-07-06 10:48:07 +0300
committerGitHub <noreply@github.com>2018-07-06 10:48:07 +0300
commit75d5828f5f6bc47177327a298a1c51453eb86844 (patch)
tree6fa3fd767d36e05ef4c67926308923014c0cf815 /plugins/GCodeReader
parentb6364b28044b5267c032eb5e4789752f2f75305f (diff)
parent183cd0182d32f1e5a3477d11891d9fed33c6c5e7 (diff)
Merge branch 'master' into fix_tests_cura_engine_backend
Diffstat (limited to 'plugins/GCodeReader')
-rw-r--r--plugins/GCodeReader/FlavorParser.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/GCodeReader/FlavorParser.py b/plugins/GCodeReader/FlavorParser.py
index ead527a61f..10f841fc43 100644
--- a/plugins/GCodeReader/FlavorParser.py
+++ b/plugins/GCodeReader/FlavorParser.py
@@ -286,9 +286,11 @@ class FlavorParser:
self._cancelled = False
# We obtain the filament diameter from the selected extruder to calculate line widths
global_stack = CuraApplication.getInstance().getGlobalContainerStack()
+
+ if not global_stack:
+ return None
- if global_stack:
- self._filament_diameter = global_stack.extruders[str(self._extruder_number)].getProperty("material_diameter", "value")
+ self._filament_diameter = global_stack.extruders[str(self._extruder_number)].getProperty("material_diameter", "value")
scene_node = CuraSceneNode()