diff --git a/screenless/bureau/bureau.py b/screenless/bureau/bureau.py index 53de1b8..39e6318 100644 --- a/screenless/bureau/bureau.py +++ b/screenless/bureau/bureau.py @@ -549,13 +549,20 @@ class Bureau(object): continue self.log.debug("got method: " + ref) - if (ref in self.commands) or (ref in self.api): + if (ref in self.commands) or (ref in self.api) or + (ref in self.webviews): if ref in self.api: if data: data = json.loads(data) ret = json.dumps(self.api[ref](data)) else: ret = json.dumps(self.api[ref]()) + elif ref in self.webviews: + if data: + data = json.loads(data) + ret = json.dumps(self.webviews[ref](data)) + else: + ret = json.dumps(self.webviews[ref]()) else: if data: ret = self.commands[ref](data)