aboutsummaryrefslogtreecommitdiffstats
path: root/gui/api/__init__.py
diff options
context:
space:
mode:
Diffstat (limited to 'gui/api/__init__.py')
-rwxr-xr-xgui/api/__init__.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/gui/api/__init__.py b/gui/api/__init__.py
index 70a4eff..77faa10 100755
--- a/gui/api/__init__.py
+++ b/gui/api/__init__.py
@@ -23,6 +23,7 @@
import cherrypy
from cherrypy.lib.httputil import parse_query_string
+import json
import urllib
import os
@@ -88,7 +89,7 @@ class API:
if cherrypy.request.method == 'POST':
cl = cherrypy.request.headers['Content-Length']
rawbody = cherrypy.request.body.read(int(cl))
- params = json.loads(rawbody)
+ params = json.loads(rawbody.decode())
try:
self.mod_rc.set_param_value(params['controllable'], params['param'], params['value'])
except ValueError as e: