From fb9fadf42cc475f0e1025dd84d414b8475a29dbd Mon Sep 17 00:00:00 2001 From: Sam Date: Tue, 19 Dec 2017 12:17:08 +1100 Subject: [PATCH] FIX: publish presence to allowed groups as well --- plugins/discourse-presence/plugin.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/discourse-presence/plugin.rb b/plugins/discourse-presence/plugin.rb index d553a50478a..f1e43f3f7e0 100644 --- a/plugins/discourse-presence/plugin.rb +++ b/plugins/discourse-presence/plugin.rb @@ -60,10 +60,13 @@ after_initialize do if topic.archetype == Archetype.private_message user_ids = User.where('admin OR moderator').pluck(:id) + topic.allowed_users.pluck(:id) + group_ids = topic.allowed_groups.pluck(:id) + MessageBus.publish( messagebus_channel, message.as_json, user_ids: user_ids, + group_ids: group_ids, max_backlog_age: MAX_BACKLOG_AGE ) else