Fix: Use 201 as HTTP return code when a package is uploaded.
authorpeusterm <manuel.peuster@uni-paderborn.de>
Thu, 15 Sep 2016 13:39:36 +0000 (15:39 +0200)
committerpeusterm <manuel.peuster@uni-paderborn.de>
Thu, 15 Sep 2016 13:39:36 +0000 (15:39 +0200)
src/emuvim/api/sonata/dummygatekeeper.py

index 83737ee..8a9416c 100755 (executable)
@@ -556,7 +556,7 @@ class Packages(fr.Resource):
             s = Service(service_uuid, file_hash, upload_path)
             GK.register_service_package(service_uuid, s)
             # generate the JSON result
-            return {"service_uuid": service_uuid, "size": size, "sha1": file_hash, "error": None}
+            return {"service_uuid": service_uuid, "size": size, "sha1": file_hash, "error": None}, 201
         except Exception as ex:
             LOG.exception("Service package upload failed:")
             return {"service_uuid": None, "size": 0, "sha1": None, "error": "upload failed"}, 500