diff options
author | Erik Johnston <erik@matrix.org> | 2019-10-02 14:08:35 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-02 14:08:35 +0100 |
commit | a5166e4d5febc0e03ba9da9db99127a797a0bc4d (patch) | |
tree | aea253a817e70889e4de547916b442a11abe8c9e /synapse/federation/transport/server.py | |
parent | Fix up some typechecking (#6150) (diff) | |
download | synapse-a5166e4d5febc0e03ba9da9db99127a797a0bc4d.tar.xz |
Land improved room list based on room stats (#6019)
Use room_stats and room_state for room directory search
Diffstat (limited to 'synapse/federation/transport/server.py')
-rw-r--r-- | synapse/federation/transport/server.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/synapse/federation/transport/server.py b/synapse/federation/transport/server.py index 7f8a16e355..0f16f21c2d 100644 --- a/synapse/federation/transport/server.py +++ b/synapse/federation/transport/server.py @@ -765,6 +765,10 @@ class PublicRoomList(BaseFederationServlet): else: network_tuple = ThirdPartyInstanceID(None, None) + if limit == 0: + # zero is a special value which corresponds to no limit. + limit = None + data = await maybeDeferred( self.handler.get_local_public_room_list, limit, @@ -800,6 +804,10 @@ class PublicRoomList(BaseFederationServlet): if search_filter is None: logger.warning("Nonefilter") + if limit == 0: + # zero is a special value which corresponds to no limit. + limit = None + data = await self.handler.get_local_public_room_list( limit=limit, since_token=since_token, |