Optimise QueryServerJoinedToRoom (#1933)

* Optimise checking if a server is in a room

* Fix queries

* Fix queries
This commit is contained in:
Neil Alexander 2021-07-21 13:06:32 +01:00 committed by GitHub
parent 2f5e4f5991
commit f0f8c7f055
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 64 additions and 38 deletions

View file

@ -181,11 +181,8 @@ type QueryServerJoinedToRoomRequest struct {
type QueryServerJoinedToRoomResponse struct {
// True if the room exists on the server
RoomExists bool `json:"room_exists"`
// True if we still believe that we are participating in the room
// True if we still believe that the server is participating in the room
IsInRoom bool `json:"is_in_room"`
// List of servers that are also in the room. This will not be populated
// if the queried ServerName is the local server name.
ServerNames []gomatrixserverlib.ServerName `json:"server_names"`
}
// QueryServerAllowedToSeeEventRequest is a request to QueryServerAllowedToSeeEvent