[IMP] openerp/http.py: accept mimetype application/json-rpc for json-rpc calls
authorRaphael Collet <rco@openerp.com>
Tue, 9 Sep 2014 08:11:33 +0000 (10:11 +0200)
committerRaphael Collet <rco@openerp.com>
Tue, 9 Sep 2014 08:11:33 +0000 (10:11 +0200)
openerp/http.py

index a67b13b..31a7f5b 100644 (file)
@@ -1278,7 +1278,7 @@ class Root(object):
         # deduce type of request
         if httprequest.args.get('jsonp'):
             return JsonRequest(httprequest)
-        if httprequest.mimetype == "application/json":
+        if httprequest.mimetype in ("application/json", "application/json-rpc"):
             return JsonRequest(httprequest)
         else:
             return HttpRequest(httprequest)