Skip to content
Snippets Groups Projects
Commit 410a74b0 authored by Erik Johnston's avatar Erik Johnston
Browse files

If timeout=0, return immediately

parent 92033e4e
No related branches found
No related tags found
No related merge requests found
...@@ -178,9 +178,13 @@ class Notifier(object): ...@@ -178,9 +178,13 @@ class Notifier(object):
if timeout: if timeout:
reactor.callLater(timeout/1000, self._timeout_listener, listener) reactor.callLater(timeout/1000, self._timeout_listener, listener)
self._register_with_keys(listener) self._register_with_keys(listener)
yield self._check_for_updates(listener) yield self._check_for_updates(listener)
if not timeout:
self._timeout_listener(listener)
return return
def _timeout_listener(self, listener): def _timeout_listener(self, listener):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment