diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2023-01-26 12:31:58 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-26 12:31:58 -0500 |
commit | ba79fb4a61784f4b5613da795a61f430af053ca6 (patch) | |
tree | d6759333a4aae6ae255c931d0bc87d87716abec7 /synapse/handlers/pagination.py | |
parent | Fix typo in release script (#14920) (diff) | |
download | synapse-ba79fb4a61784f4b5613da795a61f430af053ca6.tar.xz |
Use StrCollection in place of Collection[str] in (most) handlers code. (#14922)
Due to the increased safety of StrCollection over Collection[str] and Sequence[str].
Diffstat (limited to 'synapse/handlers/pagination.py')
-rw-r--r-- | synapse/handlers/pagination.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/handlers/pagination.py b/synapse/handlers/pagination.py index 8c8ff18a1a..1fe6567185 100644 --- a/synapse/handlers/pagination.py +++ b/synapse/handlers/pagination.py @@ -13,7 +13,7 @@ # See the License for the specific language governing permissions and # limitations under the License. import logging -from typing import TYPE_CHECKING, Collection, Dict, List, Optional, Set +from typing import TYPE_CHECKING, Dict, List, Optional, Set import attr @@ -28,7 +28,7 @@ from synapse.logging.opentracing import trace from synapse.metrics.background_process_metrics import run_as_background_process from synapse.rest.admin._base import assert_user_is_admin from synapse.streams.config import PaginationConfig -from synapse.types import JsonDict, Requester, StreamKeyType +from synapse.types import JsonDict, Requester, StrCollection, StreamKeyType from synapse.types.state import StateFilter from synapse.util.async_helpers import ReadWriteLock from synapse.util.stringutils import random_string @@ -391,7 +391,7 @@ class PaginationHandler: """ return self._delete_by_id.get(delete_id) - def get_delete_ids_by_room(self, room_id: str) -> Optional[Collection[str]]: + def get_delete_ids_by_room(self, room_id: str) -> Optional[StrCollection]: """Get all active delete ids by room Args: |