summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2018-05-23 10:04:23 +0100
committerErik Johnston <erik@matrix.org>2018-05-23 10:04:23 +0100
commit0a4bca413425fee20aed2103d6886a7701ac6b09 (patch)
tree0bc7983779c2d220639de3ce3b61cd9dab1af3e8 /synapse
parentMerge pull request #3265 from matrix-org/erikj/limit_pagination (diff)
downloadsynapse-0a4bca413425fee20aed2103d6886a7701ac6b09.tar.xz
Use iter* methods for _filter_events_for_server
Diffstat (limited to 'synapse')
-rw-r--r--synapse/handlers/federation.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/synapse/handlers/federation.py b/synapse/handlers/federation.py
index ba3ede8024..c2dc1e2690 100644
--- a/synapse/handlers/federation.py
+++ b/synapse/handlers/federation.py
@@ -479,18 +479,18 @@ class FederationHandler(BaseHandler):
         # to get all state ids that we're interested in.
         event_map = yield self.store.get_events([
             e_id
-            for key_to_eid in event_to_state_ids.values()
-            for key, e_id in key_to_eid.items()
+            for key_to_eid in event_to_state_ids.itervalues()
+            for key, e_id in key_to_eid.iteritems()
             if key[0] != EventTypes.Member or check_match(key[1])
         ])
 
         event_to_state = {
             e_id: {
                 key: event_map[inner_e_id]
-                for key, inner_e_id in key_to_eid.items()
+                for key, inner_e_id in key_to_eid.iteritems()
                 if inner_e_id in event_map
             }
-            for e_id, key_to_eid in event_to_state_ids.items()
+            for e_id, key_to_eid in event_to_state_ids.iteritems()
         }
 
         def redact_disallowed(event, state):