summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-01-06 14:56:57 +0000
committerErik Johnston <erik@matrix.org>2015-01-06 14:56:57 +0000
commit52b2c6c9c73d47a269756d8da57b4dcff54e0d21 (patch)
tree9f72b51cace6af0a407eadeaedba833bb890c18f
parentMerge branch 'erikj-perf' of github.com:matrix-org/synapse into develop (diff)
downloadsynapse-52b2c6c9c73d47a269756d8da57b4dcff54e0d21.tar.xz
Don't include None's in _get_events_txn
-rw-r--r--synapse/storage/_base.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/storage/_base.py b/synapse/storage/_base.py
index 728d1df8fa..a0b7f943fd 100644
--- a/synapse/storage/_base.py
+++ b/synapse/storage/_base.py
@@ -446,7 +446,7 @@ class SQLBaseStore(object):
         if not event_ids:
             return []
 
-        return [
+        events = [
             self._get_event_txn(
                 txn, event_id,
                 check_redacted=check_redacted,
@@ -455,6 +455,8 @@ class SQLBaseStore(object):
             for event_id in event_ids
         ]
 
+        return [e for e in events if e]
+
     def _get_event_txn(self, txn, event_id, check_redacted=True,
                        get_prev_content=False):
         sql = (