From 1e62d9ee8cb049d752af4d4f6237fd7e412800d8 Mon Sep 17 00:00:00 2001 From: Erik Johnston Date: Thu, 25 Feb 2021 13:56:55 +0000 Subject: Ensure pushers are deleted for deactivated accounts (#9285) --- synapse/handlers/deactivate_account.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'synapse/handlers/deactivate_account.py') diff --git a/synapse/handlers/deactivate_account.py b/synapse/handlers/deactivate_account.py index 94f3f3163f..3886d3124d 100644 --- a/synapse/handlers/deactivate_account.py +++ b/synapse/handlers/deactivate_account.py @@ -120,6 +120,11 @@ class DeactivateAccountHandler(BaseHandler): await self.store.user_set_password_hash(user_id, None) + # Most of the pushers will have been deleted when we logged out the + # associated devices above, but we still need to delete pushers not + # associated with devices, e.g. email pushers. + await self.store.delete_all_pushers_for_user(user_id) + # Add the user to a table of users pending deactivation (ie. # removal from all the rooms they're a member of) await self.store.add_user_pending_deactivation(user_id) -- cgit 1.4.1