Added validation to the models

This commit is contained in:
Marijn Deé 2018-11-26 14:30:17 +01:00
parent 68a90ec510
commit a382b77eaa
2 changed files with 16 additions and 2 deletions

View file

@ -159,8 +159,8 @@ class SendMaterialJob(Job):
Logger.log("e", "Request material storage on printer: I didn't understand the printer's answer.")
except json.JSONDecodeError:
Logger.log("e", "Request material storage on printer: I didn't understand the printer's answer.")
except TypeError:
Logger.log("e", "Request material storage on printer: Printer's answer was missing GUIDs.")
except ValueError:
Logger.log("e", "Request material storage on printer: Printer's answer was missing a value.")
## Retrieves a list of local materials
#