FIX: publish presence to allowed groups as well

This commit is contained in:
Sam 2017-12-19 12:17:08 +11:00
parent f315c142b1
commit fb9fadf42c
1 changed files with 3 additions and 0 deletions

View File

@ -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