diff options
-rw-r--r-- | synapse/handlers/message.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py index b63863e5b2..14fae689f2 100644 --- a/synapse/handlers/message.py +++ b/synapse/handlers/message.py @@ -268,6 +268,9 @@ class MessageHandler(BaseHandler): user, pagination_config, None ) + public_rooms = yield self.store.get_rooms(is_public=True) + public_room_ids = [r["room_id"] for r in public_rooms] + limit = pagin_config.limit if not limit: limit = 10 @@ -276,6 +279,8 @@ class MessageHandler(BaseHandler): d = { "room_id": event.room_id, "membership": event.membership, + "visibility": ("public" if event.room_id in + public_room_ids else "private"), } if event.membership == Membership.INVITE: |