summary refs log tree commit diff
path: root/synapse/rest/pusher.py
diff options
context:
space:
mode:
authorDavid Baker <dave@matrix.org>2015-01-20 11:49:48 +0000
committerDavid Baker <dave@matrix.org>2015-01-20 11:49:48 +0000
commitafb714f7bebf88ac27eac018cffa2078e2723310 (patch)
treec65a60cc08b0c5335a25b946f49255cbe4468202 /synapse/rest/pusher.py
parentRequire device language when adding a pusher. (diff)
downloadsynapse-afb714f7bebf88ac27eac018cffa2078e2723310.tar.xz
add instance_handles to pushers so we have a way to refer to them even if the push token changes.
Diffstat (limited to 'synapse/rest/pusher.py')
-rw-r--r--synapse/rest/pusher.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/rest/pusher.py b/synapse/rest/pusher.py
index 6b9a59adb6..4659c9b1d9 100644
--- a/synapse/rest/pusher.py
+++ b/synapse/rest/pusher.py
@@ -31,7 +31,7 @@ class PusherRestServlet(RestServlet):
 
         content = _parse_json(request)
 
-        reqd = ['kind', 'app_id', 'app_display_name',
+        reqd = ['instance_handle', 'kind', 'app_id', 'app_display_name',
                 'device_display_name', 'pushkey', 'lang', 'data']
         missing = []
         for i in reqd:
@@ -45,6 +45,7 @@ class PusherRestServlet(RestServlet):
         try:
             yield pusher_pool.add_pusher(
                 user_name=user.to_string(),
+                instance_handle=content['instance_handle'],
                 kind=content['kind'],
                 app_id=content['app_id'],
                 app_display_name=content['app_display_name'],