summary refs log tree commit diff
path: root/synapse/handlers/pagination.py
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2020-10-13 08:20:32 -0400
committerGitHub <noreply@github.com>2020-10-13 08:20:32 -0400
commit629a951b49ae58af43323e6829cf49d7452ebf39 (patch)
tree37148e3db9348de955356be8e1154bd076eeab18 /synapse/handlers/pagination.py
parentFix message duplication if something goes wrong after persisting the event (#... (diff)
downloadsynapse-629a951b49ae58af43323e6829cf49d7452ebf39.tar.xz
Move additional tasks to the background worker, part 4 (#8513)
Diffstat (limited to 'synapse/handlers/pagination.py')
-rw-r--r--synapse/handlers/pagination.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/handlers/pagination.py b/synapse/handlers/pagination.py
index 085b685959..426b58da9e 100644
--- a/synapse/handlers/pagination.py
+++ b/synapse/handlers/pagination.py
@@ -92,7 +92,7 @@ class PaginationHandler:
         self._retention_allowed_lifetime_min = hs.config.retention_allowed_lifetime_min
         self._retention_allowed_lifetime_max = hs.config.retention_allowed_lifetime_max
 
-        if hs.config.retention_enabled:
+        if hs.config.run_background_tasks and hs.config.retention_enabled:
             # Run the purge jobs described in the configuration file.
             for job in hs.config.retention_purge_jobs:
                 logger.info("Setting up purge job with config: %s", job)