☔ appkeys: better handling of empty request body

This commit is contained in:
Gina Häußge committed 2019-09-04 10:59:03 +02:00
1 parent 6df3cb5c12
commit a3a60c5967
1 file changed
+3
@@ -121,6 +121,9 @@ class AppKeysPlugin(octoprint.plugin.AssetPlugin,
@no_firstrun_access
def handle_request(self):
data = flask.request.json
if data is None:
return flask.make_response("Missing key request", 400)
if not "app" in data:
return flask.make_response("No app name provided", 400)