summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2017-05-22 14:58:22 +0100
committerErik Johnston <erik@matrix.org>2017-05-22 14:58:22 +0100
commit25f03cf8e9600f68b72fb5843e1e2b789d064c2a (patch)
tree1d70611609f7851c02d0c5e84c741a44a0adc0f9
parentSpeed up calculating push rules (diff)
downloadsynapse-25f03cf8e9600f68b72fb5843e1e2b789d064c2a.tar.xz
Use tuple unpacking
-rw-r--r--synapse/push/bulk_push_rule_evaluator.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/push/bulk_push_rule_evaluator.py b/synapse/push/bulk_push_rule_evaluator.py
index 3da684c6b1..f01a609e38 100644
--- a/synapse/push/bulk_push_rule_evaluator.py
+++ b/synapse/push/bulk_push_rule_evaluator.py
@@ -236,10 +236,10 @@ class RulesForRoom(object):
             # Loop through to see which member events we've seen and have rules
             # for and which we need to fetch
             for key in current_state_ids:
-                if key[0] != EventTypes.Member:
+                typ, user_id = key
+                if typ != EventTypes.Member:
                     continue
 
-                user_id = key[1]
                 if user_id in self.uninteresting_user_set:
                     continue