mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 05:35:58 +08:00
Safer check for extruder vs. global
Because it might be an empty string. Contributes to issue CURA-5054.
This commit is contained in:
parent
b797ac1a15
commit
3a832d66a9
@ -16,7 +16,7 @@ class QualityChangesGroup(QualityGroup):
|
||||
|
||||
def addNode(self, node: "QualityNode"):
|
||||
extruder_position = node.metadata.get("position")
|
||||
if not extruder_position: #Then we're a global quality changes profile.
|
||||
if extruder_position is None: #Then we're a global quality changes profile.
|
||||
if self.node_for_global is not None:
|
||||
raise RuntimeError("{group} tries to overwrite the existing node_for_global {original_global} with {new_global}".format(group = self, original_global = self.node_for_global, new_global = node))
|
||||
self.node_for_global = node
|
||||
|
Loading…
x
Reference in New Issue
Block a user