From bd5189c9f73319f566d342fc0a7fcaeaea18376f Mon Sep 17 00:00:00 2001 From: Andrew Morgan Date: Sat, 28 Jan 2023 17:54:37 +0100 Subject: Hide device displaynames from other users Some argument finagling was needed as query_local_devices can be called from requests of both local and remote users, and in the case of remote users, without a user ID. In the end, we have an option 'from_local_user_id' which tells `query_local_devices` both a) whether the request is from a local or remote user and b) if a local user, which one. --- synapse/handlers/device.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'synapse/handlers/device.py') diff --git a/synapse/handlers/device.py b/synapse/handlers/device.py index 5c06073901..563a17f888 100644 --- a/synapse/handlers/device.py +++ b/synapse/handlers/device.py @@ -1086,7 +1086,7 @@ class DeviceListUpdater(DeviceListWorkerUpdater): @measure_func("_incoming_device_list_update") async def _handle_device_updates(self, user_id: str) -> None: - "Actually handle pending updates." + """Actually handle pending updates.""" async with self._remote_edu_linearizer.queue(user_id): pending_updates = self._pending_updates.pop(user_id, []) -- cgit 1.5.1