mirror of
https://mau.dev/maunium/synapse.git
synced 2024-10-01 01:36:05 -04:00
Remove the RoomsTable object
This commit is contained in:
parent
a8e9e0b916
commit
96e400fee5
@ -49,7 +49,7 @@ class RoomStore(SQLBaseStore):
|
||||
"""
|
||||
try:
|
||||
yield self._simple_insert(
|
||||
RoomsTable.table_name,
|
||||
"rooms",
|
||||
{
|
||||
"room_id": room_id,
|
||||
"creator": room_creator_user_id,
|
||||
@ -70,9 +70,9 @@ class RoomStore(SQLBaseStore):
|
||||
A namedtuple containing the room information, or an empty list.
|
||||
"""
|
||||
return self._simple_select_one(
|
||||
table=RoomsTable.table_name,
|
||||
table="rooms",
|
||||
keyvalues={"room_id": room_id},
|
||||
retcols=RoomsTable.fields,
|
||||
retcols=("room_id", "is_public", "creator"),
|
||||
desc="get_room",
|
||||
allow_none=True,
|
||||
)
|
||||
@ -275,13 +275,3 @@ class RoomStore(SQLBaseStore):
|
||||
aliases.extend(e.content['aliases'])
|
||||
|
||||
defer.returnValue((name, aliases))
|
||||
|
||||
|
||||
class RoomsTable(object):
|
||||
table_name = "rooms"
|
||||
|
||||
fields = [
|
||||
"room_id",
|
||||
"is_public",
|
||||
"creator"
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user