diff options
author | Kegan Dougal <kegan@matrix.org> | 2015-02-11 10:03:24 +0000 |
---|---|---|
committer | Kegan Dougal <kegan@matrix.org> | 2015-02-11 10:03:24 +0000 |
commit | 9978c5c10310512493b976f482f400bf30a78729 (patch) | |
tree | 5afafbfa518af855eb654a4a060f692b0ae2332e /synapse/handlers/sync.py | |
parent | Merge branch 'develop' into application-services (diff) | |
parent | Merge pull request #60 from matrix-org/single_source_version_and_dependencies (diff) | |
download | synapse-9978c5c10310512493b976f482f400bf30a78729.tar.xz |
Merge branch 'develop' into application-services
Diffstat (limited to 'synapse/handlers/sync.py')
-rw-r--r-- | synapse/handlers/sync.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/synapse/handlers/sync.py b/synapse/handlers/sync.py index 439164ae39..7883bbd834 100644 --- a/synapse/handlers/sync.py +++ b/synapse/handlers/sync.py @@ -114,7 +114,7 @@ class SyncHandler(BaseHandler): if sync_config.gap: return self.incremental_sync_with_gap(sync_config, since_token) else: - #TODO(mjark): Handle gapless sync + # TODO(mjark): Handle gapless sync raise NotImplementedError() @defer.inlineCallbacks @@ -175,9 +175,10 @@ class SyncHandler(BaseHandler): room_id, sync_config, now_token, ) - current_state_events = yield self.state_handler.get_current_state( + current_state = yield self.state_handler.get_current_state( room_id ) + current_state_events = current_state.values() defer.returnValue(RoomSyncResult( room_id=room_id, @@ -347,9 +348,10 @@ class SyncHandler(BaseHandler): # TODO(mjark): This seems racy since this isn't being passed a # token to indicate what point in the stream this is - current_state_events = yield self.state_handler.get_current_state( + current_state = yield self.state_handler.get_current_state( room_id ) + current_state_events = current_state.values() state_at_previous_sync = yield self.get_state_at_previous_sync( room_id, since_token=since_token @@ -431,6 +433,7 @@ class SyncHandler(BaseHandler): joined = True if joined: - state_delta = yield self.state_handler.get_current_state(room_id) + res = yield self.state_handler.get_current_state(room_id) + state_delta = res.values() defer.returnValue(state_delta) |