aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xrwa/support/sessionservice/service.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/rwa/support/sessionservice/service.py b/rwa/support/sessionservice/service.py
index 95c014b..93ec919 100755
--- a/rwa/support/sessionservice/service.py
+++ b/rwa/support/sessionservice/service.py
@@ -126,7 +126,7 @@ class RWASupportSessionService(dbus.service.Object):
::
- [{"id": <host_uuid>, "https://example.org"}, {"id": <host_uuid>, "http://127.0.0.1:8000"}]
+ [{"url": "https://example.org", "uuid": <host_uuid>}, {"url": "http://127.0.0.1:8000", "uuid": <host_uuid>}]
"""
logging.info("D-Bus method call: %s()", "get_web_app_hosts")
@@ -196,7 +196,7 @@ class RWASupportSessionService(dbus.service.Object):
::
- {"id": <host_uuid>, "http://127.0.0.1:8000"}
+ {"status": "success", "host": {"url": "https://example.org", "uuid": <host_uuid>}}
**Structure of returned JSON (error):**
@@ -255,7 +255,8 @@ class RWASupportSessionService(dbus.service.Object):
logging.info('Added "%s" to "web_app_hosts" in user_settings', host_url)
- response = json.dumps(self._build_host_dict(host_uuid, host_object))
+ response = {"status": "success", "host": self._build_host_dict(host_uuid, host_object)}
+ response = json.dumps(response)
logging.info('The response to D-Bus caller: "%s"', response)
return response
@@ -272,7 +273,7 @@ class RWASupportSessionService(dbus.service.Object):
::
- [{"id": <host_uuid>, "https://example.org"}, {"id": <host_uuid>, "http://127.0.0.1:8000"}]
+ [{"url": "https://example.org", "uuid": <host_uuid>}, {"url": "http://127.0.0.1:8000", "uuid": <host_uuid>}]
"""
logging.info("D-Bus method call: %s(%s)", "remove_web_app_host", host_uuid)