summary refs log tree commit diff
path: root/synapse/handlers/register.py
diff options
context:
space:
mode:
authorAndrew Morgan <1342360+anoadragon453@users.noreply.github.com>2020-06-19 16:14:37 +0100
committerGitHub <noreply@github.com>2020-06-19 16:14:37 +0100
commit6708163271b0e274c3c0106b31e8fe27a50b48df (patch)
tree2eb5503b1d436513187fa40b1fb565302fb89abd /synapse/handlers/register.py
parentMerge pull request #45 from matrix-org/dinsic-release-v1.14.x (diff)
downloadsynapse-6708163271b0e274c3c0106b31e8fe27a50b48df.tar.xz
Performance improvements to marking expired users as inactive (#47)
This is a performance-related improvement to #13, which queried and hid active *and* already inactive users, one-by-one. This PR updates the code to query only **active**, expired users, all at once, and then mark them as inactive, all at once.
Diffstat (limited to 'synapse/handlers/register.py')
-rw-r--r--synapse/handlers/register.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/handlers/register.py b/synapse/handlers/register.py
index c7e3861054..8f9841117a 100644
--- a/synapse/handlers/register.py
+++ b/synapse/handlers/register.py
@@ -281,7 +281,7 @@ class RegistrationHandler(BaseHandler):
             yield self.store.add_account_data_for_user(
                 user_id, "im.vector.hide_profile", {"hide_profile": True}
             )
-            yield self.profile_handler.set_active(user, False, True)
+            yield self.profile_handler.set_active([user], False, True)
 
         return user_id