Remove unused autoJoin prop and move viaServers logic into RVS

this fixes the issue where autoJoining ignored viaServers
This commit is contained in:
Michael Telatynski 2021-03-24 16:45:53 +00:00
parent f340b8f7ed
commit 56dbd5f628
4 changed files with 6 additions and 17 deletions

View file

@ -273,7 +273,10 @@ class RoomViewStore extends Store<ActionPayload> {
const cli = MatrixClientPeg.get();
const address = this.state.roomAlias || this.state.roomId;
try {
await retry<void, MatrixError>(() => cli.joinRoom(address, payload.opts), NUM_JOIN_RETRY, (err) => {
await retry<void, MatrixError>(() => cli.joinRoom(address, {
viaServers: payload.via_servers,
...payload.opts,
}), NUM_JOIN_RETRY, (err) => {
// if we received a Gateway timeout then retry
return err.httpStatus === 504;
});