summary refs log tree commit diff
diff options
context:
space:
mode:
authorMatthew Hodgson <matthew@matrix.org>2018-09-07 16:33:00 +0100
committerMatthew Hodgson <matthew@matrix.org>2018-09-07 16:33:00 +0100
commitc630121b01977168d9ab4f717ca7ab1ed007b29b (patch)
tree7eda81ee9c1ef6200c1c52a9995d82e89a75260d
parenttypo (diff)
downloadsynapse-c630121b01977168d9ab4f717ca7ab1ed007b29b.tar.xz
fix typos
-rw-r--r--synapse/handlers/sync.py2
-rw-r--r--synapse/storage/roommember.py4
2 files changed, 3 insertions, 3 deletions
diff --git a/synapse/handlers/sync.py b/synapse/handlers/sync.py
index 0fe17950b3..e7ace7aa10 100644
--- a/synapse/handlers/sync.py
+++ b/synapse/handlers/sync.py
@@ -1608,7 +1608,7 @@ class SyncHandler(object):
             sync_config.filter_collection.lazy_load_members() and
             (
                 any(ev.type == EventTypes.Member for ev in batch.events) or
-                (batch.limited and any(ev.type == EventTypes.Member for ev in state)) or
+                #(batch.limited and any(ev.type == EventTypes.Member for ev in state)) or
                 since_token is None
             )
         ):
diff --git a/synapse/storage/roommember.py b/synapse/storage/roommember.py
index 8e941198be..b5d292a160 100644
--- a/synapse/storage/roommember.py
+++ b/synapse/storage/roommember.py
@@ -97,7 +97,7 @@ class RoomMemberWorkerStore(EventsWorkerStore):
             txn.execute(sql, (room_id, 5))
             res = {}
             for r in txn:
-                summary = res.setdefault(to_ascii[r[1]], {})
+                summary = res.setdefault(to_ascii(r[1]), {})
                 summary['users'].append((to_ascii(r[0]), to_ascii(r[2])))
 
             sql = (
@@ -109,7 +109,7 @@ class RoomMemberWorkerStore(EventsWorkerStore):
                 " WHERE c.type = 'm.room.member' AND c.room_id = ? group by m.membership"
             )
 
-            txn.execute(sql, (room_id, 5))
+            txn.execute(sql, (room_id,))
             for r in txn:
                 summary['count'] = r[0]