summary refs log tree commit diff
path: root/synapse/notifier.py
diff options
context:
space:
mode:
authorDavid Baker <dave@matrix.org>2015-01-22 17:46:16 +0000
committerDavid Baker <dave@matrix.org>2015-01-22 17:46:16 +0000
commit5c6189ea3eb36409c57cd269a8931dda8f30e6ec (patch)
tree6a6217c76e23359e2edcebd1020b4807f18b3073 /synapse/notifier.py
parentOops: second part of commit dc938606 (diff)
parentMerge pull request #30 from matrix-org/client_api_restructure (diff)
downloadsynapse-5c6189ea3eb36409c57cd269a8931dda8f30e6ec.tar.xz
Merge branch 'develop' into pushers
Conflicts:
	synapse/rest/__init__.py
Diffstat (limited to 'synapse/notifier.py')
-rw-r--r--synapse/notifier.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/notifier.py b/synapse/notifier.py
index b9d52d0c4c..3aec1d4af2 100644
--- a/synapse/notifier.py
+++ b/synapse/notifier.py
@@ -244,14 +244,14 @@ class Notifier(object):
             )
 
         if timeout:
-            self.clock.call_later(timeout/1000.0, _timeout_listener)
-
             self._register_with_keys(listener)
 
         yield self._check_for_updates(listener)
 
         if not timeout:
             _timeout_listener()
+        else:
+            self.clock.call_later(timeout/1000.0, _timeout_listener)
 
         return