Updated to work with OctoPrint 1.2.0

While what I've changed seems to work, I have no idea what I'm doing, so assume nothing... :-)