Allow a retraction z hop of 0 in timelapse configuration

See comment by @markwal at
https://github.com/foosel/OctoPrint/pull/1148#pullrequestreview-14802655
This commit is contained in:
Gina Häußge 2017-01-09 17:00:04 +01:00
parent dc3182c872
commit f3f60674fc

View file

@ -230,7 +230,7 @@ def setTimelapseConfig():
except ValueError:
return make_response("Invalid value for retraction Z-Hop: %r" % data["retractionZHop"])
else:
if retractionZHop > 0:
if retractionZHop >= 0:
config["options"]["retractionZHop"] = retractionZHop
else:
return make_response("Invalid value for retraction Z-Hop: %d" % retractionZHop)