diff options
author | Erik Johnston <erik@matrix.org> | 2017-02-21 13:45:02 +0000 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2017-02-21 13:45:02 +0000 |
commit | 3346a213241544faa48b1243906452a646f93a4a (patch) | |
tree | 9b94212dbce78d9bc1e82cf99204518fc72fe5ed /synapse/handlers/room.py | |
parent | Update metrics-howto.rst (diff) | |
parent | Bump version and changelog (diff) | |
download | synapse-3346a213241544faa48b1243906452a646f93a4a.tar.xz |
Merge branch 'release-v0.19.2' of github.com:matrix-org/synapse v0.19.2
Diffstat (limited to 'synapse/handlers/room.py')
-rw-r--r-- | synapse/handlers/room.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py index 7e7671c9a2..99cb7db0db 100644 --- a/synapse/handlers/room.py +++ b/synapse/handlers/room.py @@ -356,7 +356,7 @@ class RoomCreationHandler(BaseHandler): class RoomContextHandler(BaseHandler): @defer.inlineCallbacks - def get_event_context(self, user, room_id, event_id, limit, is_guest): + def get_event_context(self, user, room_id, event_id, limit): """Retrieves events, pagination tokens and state around a given event in a room. @@ -375,12 +375,15 @@ class RoomContextHandler(BaseHandler): now_token = yield self.hs.get_event_sources().get_current_token() + users = yield self.store.get_users_in_room(room_id) + is_peeking = user.to_string() not in users + def filter_evts(events): return filter_events_for_client( self.store, user.to_string(), events, - is_peeking=is_guest + is_peeking=is_peeking ) event = yield self.store.get_event(event_id, get_prev_content=True, |