summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2016-09-05 10:43:32 +0100
committerErik Johnston <erik@matrix.org>2016-09-05 10:43:32 +0100
commit80a6a445faba2ea39ff497517e4ef92c882a11b0 (patch)
tree752256c178e542264cc99209c9cf8e1864fdcfa3 /synapse/storage
parentMake bulk_get_push_rules_for_room use get_joined_users_from_context cache (diff)
downloadsynapse-80a6a445faba2ea39ff497517e4ef92c882a11b0.tar.xz
Only fetch local pushers
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/push_rule.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/storage/push_rule.py b/synapse/storage/push_rule.py
index c312ee39a2..789766d5be 100644
--- a/synapse/storage/push_rule.py
+++ b/synapse/storage/push_rule.py
@@ -151,12 +151,14 @@ class PushRuleStore(SQLBaseStore):
         # generating them for bot / AS users etc, we only do so for people who've
         # sent a read receipt into the room.
 
-        local_users_in_room = yield self._get_joined_users_from_context(
+        users_in_room = yield self._get_joined_users_from_context(
             room_id, state_group, current_state_ids,
             on_invalidate=cache_context.invalidate,
             event=event,
         )
 
+        local_users_in_room = set(u for u in users_in_room if self.hs.is_mine_id(u))
+
         # users in the room who have pushers need to get push rules run because
         # that's how their pushers work
         if_users_with_pushers = yield self.get_if_users_have_pushers(