summary refs log tree commit diff
path: root/synapse/storage/databases
diff options
context:
space:
mode:
authorAndrew Morgan <1342360+anoadragon453@users.noreply.github.com>2021-09-01 10:13:01 +0100
committerGitHub <noreply@github.com>2021-09-01 09:13:01 +0000
commit3693ea61f5f56f4a49cce7e2b3ecd304f014d8cc (patch)
tree4434bf1ba7dbb969323252e560ba0003879518e8 /synapse/storage/databases
parentMove the sessions delta to the latest schema version. (#10725) (diff)
downloadsynapse-3693ea61f5f56f4a49cce7e2b3ecd304f014d8cc.tar.xz
Fix iteration in _remove_deleted_email_pushers background job. (#10734)
Diffstat (limited to 'synapse/storage/databases')
-rw-r--r--synapse/storage/databases/main/pusher.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/storage/databases/main/pusher.py b/synapse/storage/databases/main/pusher.py
index e47caa2125..63ac09c61d 100644
--- a/synapse/storage/databases/main/pusher.py
+++ b/synapse/storage/databases/main/pusher.py
@@ -430,10 +430,11 @@ class PusherWorkerStore(SQLBaseStore):
             """
 
             txn.execute(sql, (last_pusher, batch_size))
+            rows = txn.fetchall()
 
             last = None
             num_deleted = 0
-            for row in txn:
+            for row in rows:
                 last = row[0]
                 num_deleted += 1
                 self.db_pool.simple_delete_txn(