summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-05-19 15:27:00 +0100
committerErik Johnston <erik@matrix.org>2015-05-19 15:27:00 +0100
commitaa729349ddf23c0abb5096581a317783a8f60aa6 (patch)
tree6cf953c3800a25e6716dd0c16d5410b0a663687e /synapse
parentAdd a timeout param to get_event (diff)
downloadsynapse-aa729349ddf23c0abb5096581a317783a8f60aa6.tar.xz
Fix event_backwards_extrem insertion to ignore outliers
Diffstat (limited to 'synapse')
-rw-r--r--synapse/storage/event_federation.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/synapse/storage/event_federation.py b/synapse/storage/event_federation.py
index a1982dfbb5..2880850506 100644
--- a/synapse/storage/event_federation.py
+++ b/synapse/storage/event_federation.py
@@ -337,12 +337,13 @@ class EventFederationStore(SQLBaseStore):
                 " WHERE event_id = ? AND room_id = ?"
                 " )"
                 " AND NOT EXISTS ("
-                " SELECT 1 FROM events WHERE event_id = ? AND room_id = ?"
+                " SELECT 1 FROM events WHERE event_id = ? AND room_id = ? "
+                " AND outlier = ?"
                 " )"
             )
 
             txn.executemany(query, [
-                (e_id, room_id, e_id, room_id, e_id, room_id, )
+                (e_id, room_id, e_id, room_id, e_id, room_id, False)
                 for e_id, _ in prev_events
             ])