summary refs log tree commit diff
diff options
context:
space:
mode:
authorMatthew Hodgson <matthew@arasphere.net>2018-06-26 10:59:19 +0100
committerGitHub <noreply@github.com>2018-06-26 10:59:19 +0100
commitc695a8d003d06b790bdc39481ee0a53f0ed2ad8c (patch)
treebb0b5ca96181a4d70faff568f8db7c0d35d69113
parentMerge pull request #3448 from matrix-org/matthew/gdpr-deactivate-admin-api (diff)
parentFix error on deleting users pending deactivation (diff)
downloadsynapse-c695a8d003d06b790bdc39481ee0a53f0ed2ad8c.tar.xz
Merge pull request #3449 from matrix-org/dbkr/fix_deactivate_account_multiple_pending
Fix error on deleting users pending deactivation
-rw-r--r--synapse/storage/registration.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/storage/registration.py b/synapse/storage/registration.py

index 9c9cf46e7f..0d18f6d869 100644 --- a/synapse/storage/registration.py +++ b/synapse/storage/registration.py
@@ -623,7 +623,9 @@ class RegistrationStore(RegistrationWorkerStore, Removes the given user to the table of users who need to be parted from all the rooms they're in, effectively marking that user as fully deactivated. """ - return self._simple_delete_one( + # XXX: This should be simple_delete_one but we failed to put a unique index on + # the table, so somehow duplicate entries have ended up in it. + return self._simple_delete( "users_pending_deactivation", keyvalues={ "user_id": user_id,