Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Merge branch 'release-v0.19.2' of github.com:matrix-org/synapse
Browse files Browse the repository at this point in the history
  • Loading branch information
erikjohnston committed Feb 21, 2017
2 parents 6184f6f + 30ecfef commit 3346a21
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
7 changes: 7 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
Changes in synapse v0.19.2 (2017-02-20)
=======================================

* Fix bug with event visibility check in /context/ API. Thanks to Tokodomo for
pointing it out! (PR #1929)


Changes in synapse v0.19.1 (2017-02-09)
=======================================

Expand Down
2 changes: 1 addition & 1 deletion synapse/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
""" This is a reference implementation of a Matrix home server.
"""

__version__ = "0.19.1"
__version__ = "0.19.2"
7 changes: 5 additions & 2 deletions synapse/handlers/room.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ def send(etype, content, **kwargs):

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.
Expand All @@ -375,12 +375,15 @@ def get_event_context(self, user, room_id, event_id, limit, is_guest):

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,
Expand Down
1 change: 0 additions & 1 deletion synapse/rest/client/v1/room.py
Original file line number Diff line number Diff line change
Expand Up @@ -505,7 +505,6 @@ def on_GET(self, request, room_id, event_id):
room_id,
event_id,
limit,
requester.is_guest,
)

if not results:
Expand Down

0 comments on commit 3346a21

Please sign in to comment.