summary refs log tree commit diff
path: root/synapse/storage/databases/main/pusher.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2021-01-26 14:15:26 +0000
committerErik Johnston <erik@matrix.org>2021-01-26 14:15:26 +0000
commit512e313f18308d1adcb967bf9f05f8eb1ce45753 (patch)
treec745520eaf73cd29144c1ba0efb3d83335897626 /synapse/storage/databases/main/pusher.py
parentMerge remote-tracking branch 'origin/release-v1.26.0' into matrix-org-hotfixes (diff)
parentPrecompute joined hosts and store in Redis (#9198) (diff)
downloadsynapse-512e313f18308d1adcb967bf9f05f8eb1ce45753.tar.xz
Merge remote-tracking branch 'origin/develop' into matrix-org-hotfixes
Diffstat (limited to 'synapse/storage/databases/main/pusher.py')
-rw-r--r--synapse/storage/databases/main/pusher.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/storage/databases/main/pusher.py b/synapse/storage/databases/main/pusher.py

index bc7621b8d6..2687ef3e43 100644 --- a/synapse/storage/databases/main/pusher.py +++ b/synapse/storage/databases/main/pusher.py
@@ -344,7 +344,9 @@ class PusherStore(PusherWorkerStore): txn, self.get_if_user_has_pusher, (user_id,) ) - self.db_pool.simple_delete_one_txn( + # It is expected that there is exactly one pusher to delete, but + # if it isn't there (or there are multiple) delete them all. + self.db_pool.simple_delete_txn( txn, "pushers", {"app_id": app_id, "pushkey": pushkey, "user_name": user_id},