summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--synapse/metrics/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/metrics/__init__.py b/synapse/metrics/__init__.py
index e014b415f3..0be9772991 100644
--- a/synapse/metrics/__init__.py
+++ b/synapse/metrics/__init__.py
@@ -158,8 +158,8 @@ def runUntilCurrentTimer(func):
 
     @functools.wraps(func)
     def f(*args, **kwargs):
-        start = time.time() * 1000
         pending_calls = len(reactor.getDelayedCalls())
+        start = time.time() * 1000
         ret = func(*args, **kwargs)
         end = time.time() * 1000
         tick_time.inc_by(end - start)