Browse Source

CURA-4890 Empty material no longer displayed as Unknown

"Get learned how to make Cura more better-er!"
Ian Paschal 7 years ago
parent
commit
3eab99c25c
1 changed files with 3 additions and 1 deletions
  1. 3 1
      plugins/UM3NetworkPrinting/ClusterUM3OutputDevice.py

+ 3 - 1
plugins/UM3NetworkPrinting/ClusterUM3OutputDevice.py

@@ -381,6 +381,8 @@ class ClusterUM3OutputDevice(NetworkedPrinterOutputDevice):
             extruder.updateHotendID(extruder_data.get("print_core_id", ""))
 
             material_data = extruder_data["material"]
+
+            print()
             if extruder.activeMaterial is None or extruder.activeMaterial.guid != material_data["guid"]:
                 containers = ContainerRegistry.getInstance().findInstanceContainers(type="material",
                                                                                     GUID=material_data["guid"])
@@ -396,7 +398,7 @@ class ClusterUM3OutputDevice(NetworkedPrinterOutputDevice):
                     color = material_data["color"]
                     brand = material_data["brand"]
                     material_type = material_data["material"]
-                    name = "Unknown"
+                    name = "Empty" if material_data["material"] == "empty" else "Unknown"
 
                 material = MaterialOutputModel(guid=material_data["guid"], type=material_type,
                                                brand=brand, color=color, name=name)