summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorEric Eastwood <erice@element.io>2021-07-19 04:16:46 -0500
committerGitHub <noreply@github.com>2021-07-19 10:16:46 +0100
commit7387d6f6249277482964e588462619c8b23a9d82 (patch)
tree599da7d52e3172ffca585da7d77dd877c99e701a /synapse
parentOne last inline type hint (for the whole repo) (#10418) (diff)
downloadsynapse-7387d6f6249277482964e588462619c8b23a9d82.tar.xz
Remove unused `events_by_room` (#10421)
It looks like it was first used and introduced in https://github.com/matrix-org/synapse/commit/5130d80d79fe1f95ce03b8f1cfd4fbf0a32f5ac8#diff-8a4a36a7728107b2ccaff2cb405dbab229a1100fe50653a63d1aa9ac10ae45e8R305 but the 

But the usage was removed in https://github.com/matrix-org/synapse/commit/4c6a31cd6efa25be4c9f1b357e8f92065fac63eb#diff-8a4a36a7728107b2ccaff2cb405dbab229a1100fe50653a63d1aa9ac10ae45e8
Diffstat (limited to '')
-rw-r--r--synapse/storage/databases/main/events.py4
1 files changed, 0 insertions, 4 deletions
diff --git a/synapse/storage/databases/main/events.py b/synapse/storage/databases/main/events.py
index ec8579b9ad..a396a201d4 100644
--- a/synapse/storage/databases/main/events.py
+++ b/synapse/storage/databases/main/events.py
@@ -2010,10 +2010,6 @@ class PersistEventsStore:
 
         Forward extremities are handled when we first start persisting the events.
         """
-        events_by_room: Dict[str, List[EventBase]] = {}
-        for ev in events:
-            events_by_room.setdefault(ev.room_id, []).append(ev)
-
         query = (
             "INSERT INTO event_backward_extremities (event_id, room_id)"
             " SELECT ?, ? WHERE NOT EXISTS ("