summary refs log tree commit diff
path: root/synapse/storage/databases/main/registration.py
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2020-10-26 14:17:31 -0400
committerGitHub <noreply@github.com>2020-10-26 14:17:31 -0400
commit10f45d85bb355c66110b9221b0aa09010d2d03ad (patch)
treebc315cfe33e2d9d53c221ae17d5dbe945f8d7579 /synapse/storage/databases/main/registration.py
parentSplit admin API for reported events into a detail and a list view (#8539) (diff)
downloadsynapse-10f45d85bb355c66110b9221b0aa09010d2d03ad.tar.xz
Add type hints for account validity handler (#8620)
This also fixes a bug by fixing handling of an account which doesn't expire.
Diffstat (limited to '')
-rw-r--r--synapse/storage/databases/main/registration.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/databases/main/registration.py b/synapse/storage/databases/main/registration.py
index b0329e17ec..e7b17a7385 100644
--- a/synapse/storage/databases/main/registration.py
+++ b/synapse/storage/databases/main/registration.py
@@ -240,13 +240,13 @@ class RegistrationWorkerStore(CacheInvalidationWorkerStore):
             desc="get_renewal_token_for_user",
         )
 
-    async def get_users_expiring_soon(self) -> List[Dict[str, int]]:
+    async def get_users_expiring_soon(self) -> List[Dict[str, Any]]:
         """Selects users whose account will expire in the [now, now + renew_at] time
         window (see configuration for account_validity for information on what renew_at
         refers to).
 
         Returns:
-            A list of dictionaries mapping user ID to expiration time (in milliseconds).
+            A list of dictionaries, each with a user ID and expiration time (in milliseconds).
         """
 
         def select_users_txn(txn, now_ms, renew_at):