summary refs log tree commit diff
path: root/synapse/handlers/pagination.py
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2021-09-29 06:44:15 -0400
committerGitHub <noreply@github.com>2021-09-29 06:44:15 -0400
commit94b620a5edd6b5bc55c8aad6e00a11cc6bf210fa (patch)
treef05585bffb2b2b093ddaafd18f4959e21dcc8eee /synapse/handlers/pagination.py
parentImplement MSC3069: Guest support on whoami (#9655) (diff)
downloadsynapse-94b620a5edd6b5bc55c8aad6e00a11cc6bf210fa.tar.xz
Use direct references for configuration variables (part 6). (#10916)
Diffstat (limited to 'synapse/handlers/pagination.py')
-rw-r--r--synapse/handlers/pagination.py14
1 files changed, 10 insertions, 4 deletions
diff --git a/synapse/handlers/pagination.py b/synapse/handlers/pagination.py
index a5301ece6f..176e4dfdd4 100644
--- a/synapse/handlers/pagination.py
+++ b/synapse/handlers/pagination.py
@@ -85,12 +85,18 @@ class PaginationHandler:
         self._purges_by_id: Dict[str, PurgeStatus] = {}
         self._event_serializer = hs.get_event_client_serializer()
 
-        self._retention_default_max_lifetime = hs.config.retention_default_max_lifetime
+        self._retention_default_max_lifetime = (
+            hs.config.server.retention_default_max_lifetime
+        )
 
-        self._retention_allowed_lifetime_min = hs.config.retention_allowed_lifetime_min
-        self._retention_allowed_lifetime_max = hs.config.retention_allowed_lifetime_max
+        self._retention_allowed_lifetime_min = (
+            hs.config.server.retention_allowed_lifetime_min
+        )
+        self._retention_allowed_lifetime_max = (
+            hs.config.server.retention_allowed_lifetime_max
+        )
 
-        if hs.config.worker.run_background_tasks and hs.config.retention_enabled:
+        if hs.config.worker.run_background_tasks and hs.config.server.retention_enabled:
             # Run the purge jobs described in the configuration file.
             for job in hs.config.server.retention_purge_jobs:
                 logger.info("Setting up purge job with config: %s", job)