summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-05-18 14:03:46 +0100
committerErik Johnston <erik@matrix.org>2015-05-18 14:03:46 +0100
commit4d1b6f4ad1bbae71c6c941b5951d9f9043ddace4 (patch)
tree781138fa5408dab3dacbb950a42c2d228530ca39 /synapse/storage
parentMerge branch 'erikj/events_move' of github.com:matrix-org/synapse into erikj/... (diff)
downloadsynapse-4d1b6f4ad1bbae71c6c941b5951d9f9043ddace4.tar.xz
Remove rejected events if we don't want rejected events
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/events.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/synapse/storage/events.py b/synapse/storage/events.py
index 25fb49a28d..5a04d45e1e 100644
--- a/synapse/storage/events.py
+++ b/synapse/storage/events.py
@@ -643,6 +643,9 @@ class EventsStore(SQLBaseStore):
                 events,
             )
 
+        if not allow_rejected:
+            rows[:] = [r for r in rows if not r["rejects"]]
+
         res = yield defer.gatherResults(
             [
                 defer.maybeDeferred(