From ac12b5fde8593fae7ee93047d79909db5bfa1587 Mon Sep 17 00:00:00 2001 From: Richard van der Hoff Date: Fri, 25 Feb 2022 12:42:55 +0000 Subject: [PATCH] Skip conversion to list --- synapse/handlers/federation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/synapse/handlers/federation.py b/synapse/handlers/federation.py index 4e9c2b951fe9..98d850cb69d6 100644 --- a/synapse/handlers/federation.py +++ b/synapse/handlers/federation.py @@ -1006,7 +1006,7 @@ async def get_state_ids_for_pdu(self, room_id: str, event_id: str) -> List[str]: # get_state_groups_ids should return exactly one result assert len(state_groups) == 1 - _, state_map = list(state_groups.items()).pop() + state_map = next(iter(state_groups.values())) if event.is_state(): # Get previous state