Don't cache searched in /publicRooms
This commit is contained in:
parent
418bcd4309
commit
74d4cdee25
|
@ -41,11 +41,15 @@ class RoomListHandler(BaseHandler):
|
||||||
|
|
||||||
def get_local_public_room_list(self, limit=None, since_token=None,
|
def get_local_public_room_list(self, limit=None, since_token=None,
|
||||||
search_filter=None):
|
search_filter=None):
|
||||||
|
if search_filter:
|
||||||
|
# We explicitly don't bother caching searches.
|
||||||
|
return self._get_public_room_list(limit, since_token, search_filter)
|
||||||
|
|
||||||
result = self.response_cache.get((limit, since_token))
|
result = self.response_cache.get((limit, since_token))
|
||||||
if not result:
|
if not result:
|
||||||
result = self.response_cache.set(
|
result = self.response_cache.set(
|
||||||
(limit, since_token),
|
(limit, since_token),
|
||||||
self._get_public_room_list(limit, since_token, search_filter)
|
self._get_public_room_list(limit, since_token)
|
||||||
)
|
)
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue