mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-04 22:14:57 -04:00
Add typing information to the device handler. (#8407)
This commit is contained in:
parent
9ca6341969
commit
b460a088c6
4 changed files with 59 additions and 38 deletions
|
@ -911,7 +911,7 @@ class DeviceStore(DeviceWorkerStore, DeviceBackgroundUpdateStore):
|
|||
self._clock.looping_call(self._prune_old_outbound_device_pokes, 60 * 60 * 1000)
|
||||
|
||||
async def store_device(
|
||||
self, user_id: str, device_id: str, initial_device_display_name: str
|
||||
self, user_id: str, device_id: str, initial_device_display_name: Optional[str]
|
||||
) -> bool:
|
||||
"""Ensure the given device is known; add it to the store if not
|
||||
|
||||
|
@ -1029,7 +1029,7 @@ class DeviceStore(DeviceWorkerStore, DeviceBackgroundUpdateStore):
|
|||
)
|
||||
|
||||
async def update_remote_device_list_cache_entry(
|
||||
self, user_id: str, device_id: str, content: JsonDict, stream_id: int
|
||||
self, user_id: str, device_id: str, content: JsonDict, stream_id: str
|
||||
) -> None:
|
||||
"""Updates a single device in the cache of a remote user's devicelist.
|
||||
|
||||
|
@ -1057,7 +1057,7 @@ class DeviceStore(DeviceWorkerStore, DeviceBackgroundUpdateStore):
|
|||
user_id: str,
|
||||
device_id: str,
|
||||
content: JsonDict,
|
||||
stream_id: int,
|
||||
stream_id: str,
|
||||
) -> None:
|
||||
if content.get("deleted"):
|
||||
self.db_pool.simple_delete_txn(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue