Fix /messages on workers when no from param specified.

If no `from` param is specified we calculate and use the "current
token" that inlcuded typing, presence, etc. These are unused during
pagination and are not available on workers, so we simply don't
calculate them.
This commit is contained in:
Erik Johnston 2019-06-24 10:06:51 +01:00
parent c753c098dd
commit dddf20e8e1
2 changed files with 19 additions and 17 deletions

View file

@ -180,9 +180,7 @@ class PaginationHandler(object):
room_token = pagin_config.from_token.room_key
else:
pagin_config.from_token = (
yield self.hs.get_event_sources().get_current_token_for_room(
room_id=room_id
)
yield self.hs.get_event_sources().get_current_token_for_pagination()
)
room_token = pagin_config.from_token.room_key