mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2024-12-20 23:44:19 -05:00
Merge pull request #481 from matrix-org/erikj/SYN-589
Don't include old left rooms in /sync
This commit is contained in:
commit
ea47760bd8
@ -585,6 +585,7 @@ class SyncHandler(BaseHandler):
|
|||||||
sync_config, leave_event, since_token, tags_by_room,
|
sync_config, leave_event, since_token, tags_by_room,
|
||||||
account_data_by_room
|
account_data_by_room
|
||||||
)
|
)
|
||||||
|
if room_sync:
|
||||||
archived.append(room_sync)
|
archived.append(room_sync)
|
||||||
|
|
||||||
invited = [
|
invited = [
|
||||||
@ -726,6 +727,9 @@ class SyncHandler(BaseHandler):
|
|||||||
|
|
||||||
leave_token = since_token.copy_and_replace("room_key", stream_token)
|
leave_token = since_token.copy_and_replace("room_key", stream_token)
|
||||||
|
|
||||||
|
if since_token.is_after(leave_token):
|
||||||
|
defer.returnValue(None)
|
||||||
|
|
||||||
batch = yield self.load_filtered_recents(
|
batch = yield self.load_filtered_recents(
|
||||||
leave_event.room_id, sync_config, leave_token, since_token,
|
leave_event.room_id, sync_config, leave_token, since_token,
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user