From e1e529d818510b335cba3db02656616ee4eb7267 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20K=C3=B6sters?= Date: Sun, 30 May 2021 22:01:12 +0200 Subject: [PATCH] fix: don't apply push rules for users of other homeservers --- src/database/rooms.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/database/rooms.rs b/src/database/rooms.rs index 6b17f398..703314e6 100644 --- a/src/database/rooms.rs +++ b/src/database/rooms.rs @@ -725,8 +725,9 @@ impl Rooms { .users .iter() .filter_map(|r| r.ok()) - .filter(|user_id| self.is_joined(&user_id, &pdu.room_id).unwrap_or(false)) + .filter(|user_id| user_id.server_name() == db.globals.server_name()) .filter(|user_id| !db.users.is_deactivated(user_id).unwrap_or(false)) + .filter(|user_id| self.is_joined(&user_id, &pdu.room_id).unwrap_or(false)) { // Don't notify the user of their own events if user == pdu.sender {