[Kimchi-devel] [PATCH] [Wok 3/6] Use status code 200 for PUT requests on resource

Lucio Correia luciojhc at linux.vnet.ibm.com
Wed Jun 8 19:27:12 UTC 2016


Some PUT requests on resource have no status code
defined. Other were returning 202, which is not the
best option for PUT requests.

Signed-off-by: Lucio Correia <luciojhc at linux.vnet.ibm.com>
---
 src/wok/control/base.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/wok/control/base.py b/src/wok/control/base.py
index b861b9c..9b34c55 100644
--- a/src/wok/control/base.py
+++ b/src/wok/control/base.py
@@ -263,6 +263,7 @@ class Resource(object):
         args = list(self.model_args) + [params]
         ident = update(*args)
         self._redirect(ident)
+        cherrypy.response.status = 200
         self.lookup()
         return self.get()
 
-- 
1.9.1




More information about the Kimchi-devel mailing list