From 77a6c459d8230f3dbbadb4ac5b5081e5871dde02 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Fri, 11 Nov 2016 11:53:13 +0100 Subject: [PATCH] Move initialisation of areas closer to where it's used Makes the code more easy to follow. Contributes to issue CURA-2625. --- cura/BuildVolume.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cura/BuildVolume.py b/cura/BuildVolume.py index 6f0a708ee2..54788ceb08 100644 --- a/cura/BuildVolume.py +++ b/cura/BuildVolume.py @@ -377,7 +377,6 @@ class BuildVolume(SceneNode): return self._error_areas = [] - areas = [] machine_width = self._global_container_stack.getProperty("machine_width", "value") machine_depth = self._global_container_stack.getProperty("machine_depth", "value") @@ -448,7 +447,7 @@ class BuildVolume(SceneNode): disallowed_polygons.extend(prime_polygons) # Extend every area already in the disallowed_areas with the skirt size. - areas.extend(self._computeDisallowedAreasStatic()) + areas = self._computeDisallowedAreasStatic() # Check if the prime tower area intersects with any of the other areas. # If this is the case, add it to the error area's so it can be drawn in red.