summary refs log tree commit diff
path: root/src/RoomDirectoryModel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/RoomDirectoryModel.cpp')
-rw-r--r--src/RoomDirectoryModel.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/RoomDirectoryModel.cpp b/src/RoomDirectoryModel.cpp

index de5d430a..cfa2b623 100644 --- a/src/RoomDirectoryModel.cpp +++ b/src/RoomDirectoryModel.cpp
@@ -98,6 +98,15 @@ RoomDirectoryModel::getViasForRoom(const std::vector<std::string> &aliases) std::back_inserter(vias), [](const auto &alias) { return alias.substr(alias.find(":") + 1); }); + // When joining a room hosted on a homeserver other than the one the + // account has been registered on, the room's server has to be explicitly + // specified in the "server_name=..." URL parameter of the Matrix Join Room + // request. For more details consult the specs: + // https://matrix.org/docs/spec/client_server/r0.6.1#post-matrix-client-r0-join-roomidoralias + if (!server_.empty()) { + vias.push_back(server_); + } + return vias; }