mirror of
https://github.com/element-hq/synapse.git
synced 2024-12-18 08:54:54 +03:00
Rename get_public_room_list() to get_published_rooms()
This commit is contained in:
parent
d88e20cdb9
commit
0dd8953cbc
2 changed files with 3 additions and 2 deletions
|
@ -532,7 +532,7 @@ class RoomMemberHandler(BaseHandler):
|
|||
class RoomListHandler(BaseHandler):
|
||||
|
||||
@defer.inlineCallbacks
|
||||
def get_public_room_list(self):
|
||||
def get_published_rooms(self):
|
||||
chunk = yield self.store.get_rooms(is_public=True)
|
||||
results = yield defer.gatherResults(
|
||||
[
|
||||
|
|
|
@ -273,12 +273,13 @@ class JoinRoomAliasServlet(ClientV1RestServlet):
|
|||
|
||||
# TODO: Needs unit testing
|
||||
class PublicRoomListRestServlet(ClientV1RestServlet):
|
||||
# TODO(paul): Can't rename this now but 'v2 ought to call this publishedRooms
|
||||
PATTERN = client_path_pattern("/publicRooms$")
|
||||
|
||||
@defer.inlineCallbacks
|
||||
def on_GET(self, request):
|
||||
handler = self.handlers.room_list_handler
|
||||
data = yield handler.get_public_room_list()
|
||||
data = yield handler.get_published_rooms()
|
||||
defer.returnValue((200, data))
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue