summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2015-12-22 14:03:24 +0000
committerMark Haines <mark.haines@matrix.org>2015-12-22 14:03:24 +0000
commit251aafcccad74aef96def0adbf5d9387e1d19199 (patch)
treea567338b8a3f8d0c58c572d8ea553713af879b6d /synapse
parentMerge remote-tracking branch 'origin/develop' into markjh/guest_access (diff)
downloadsynapse-251aafcccad74aef96def0adbf5d9387e1d19199.tar.xz
Use a list comprehension
Diffstat (limited to '')
-rw-r--r--synapse/handlers/sync.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/synapse/handlers/sync.py b/synapse/handlers/sync.py
index 4753166a0c..38c185cd54 100644
--- a/synapse/handlers/sync.py
+++ b/synapse/handlers/sync.py
@@ -195,9 +195,10 @@ class SyncHandler(BaseHandler):
         now_token = yield self.event_sources.get_current_token()
 
         if sync_config.is_guest:
-            room_list = []
-            for room_id in sync_config.filter.list_rooms():
-                room_list.append(GuestRoom(room_id, Membership.JOIN))
+            room_list = [
+                GuestRoom(room_id, Membership.JOIN)
+                for room_id in sync_config.filter.list_rooms()
+            ]
 
             account_data = {}
             account_data_by_room = {}