From 9dc3293e0b3a5cbf6fcc4a0cef7386b531190882 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Tue, 7 Jun 2022 07:43:35 -0400 Subject: Consolidate the logic of delete_device/delete_devices. (#12970) By always using delete_devices and sometimes passing a list with a single device ID. Previously these methods had gotten out of sync with each other and it seems there's little benefit to the single-device variant. --- synapse/rest/client/devices.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'synapse/rest/client/devices.py') diff --git a/synapse/rest/client/devices.py b/synapse/rest/client/devices.py index ad6fd6492b..6fab102437 100644 --- a/synapse/rest/client/devices.py +++ b/synapse/rest/client/devices.py @@ -147,7 +147,9 @@ class DeviceRestServlet(RestServlet): can_skip_ui_auth=True, ) - await self.device_handler.delete_device(requester.user.to_string(), device_id) + await self.device_handler.delete_devices( + requester.user.to_string(), [device_id] + ) return 200, {} async def on_PUT( -- cgit 1.4.1