diff options
author | Mark Haines <mark.haines@matrix.org> | 2014-08-27 15:31:04 +0100 |
---|---|---|
committer | Mark Haines <mark.haines@matrix.org> | 2014-08-27 16:51:54 +0100 |
commit | b30358f439aeec4e249c0d21d761cf6742e65578 (patch) | |
tree | dc22532c93f3af8005d67942fb32c3f0710c808e /synapse/handlers | |
parent | Start updating state handling to use snapshots (diff) | |
download | synapse-b30358f439aeec4e249c0d21d761cf6742e65578.tar.xz |
add _get_room_member, fix datastore methods
Diffstat (limited to 'synapse/handlers')
-rw-r--r-- | synapse/handlers/federation.py | 5 | ||||
-rw-r--r-- | synapse/handlers/room.py | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/synapse/handlers/federation.py b/synapse/handlers/federation.py index 4f773f6e58..7253f56322 100644 --- a/synapse/handlers/federation.py +++ b/synapse/handlers/federation.py @@ -214,7 +214,7 @@ class FederationHandler(BaseHandler): @log_function @defer.inlineCallbacks - def do_invite_join(self, target_host, room_id, joinee, content): + def do_invite_join(self, target_host, room_id, joinee, content, snapshot): hosts = yield self.store.get_joined_hosts_for_room(room_id) if self.hs.hostname in hosts: @@ -244,7 +244,8 @@ class FederationHandler(BaseHandler): new_event.destinations = [target_host] - yield self.handle_new_event(new_event) + snapshot.fill_out_prev_events(new_event) + yield self.handle_new_event(new_event, snapshot) # TODO (erikj): Time out here. d = defer.Deferred() diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py index 47dcc6544d..7b4b051888 100644 --- a/synapse/handlers/room.py +++ b/synapse/handlers/room.py @@ -637,7 +637,7 @@ class RoomMemberHandler(BaseRoomHandler): if should_do_dance: handler = self.hs.get_handlers().federation_handler have_joined = yield handler.do_invite_join( - room_host, room_id, event.user_id, event.content + room_host, room_id, event.user_id, event.content, snapshot ) # We want to do the _do_update inside the room lock. |