summary refs log tree commit diff
path: root/synapse/util/async.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/util/async.py')
-rw-r--r--synapse/util/async.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/synapse/util/async.py b/synapse/util/async.py

index 3d3fbe182c..1219d927db 100644 --- a/synapse/util/async.py +++ b/synapse/util/async.py
@@ -24,3 +24,9 @@ def sleep(seconds): reactor.callLater(seconds, d.callback, seconds) with PreserveLoggingContext(): yield d + +def run_on_reactor(): + """ This will cause the rest of the function to be invoked upon the next + iteration of the main loop + """ + return sleep(0)