forked from mystiq/hydrogen-web
Error of interpretation of the 403 status at the last update. Fixed
This commit is contained in:
parent
e345d0b33e
commit
66a59e6f4d
1 changed files with 3 additions and 1 deletions
|
@ -216,8 +216,10 @@ export class RoomViewModel extends ViewModel {
|
|||
} catch (exc) {
|
||||
if ((exc.statusCode ?? exc.status) === 400) {
|
||||
this._sendError = new Error(`/join : '${roomName}' was not legal room ID or room alias`);
|
||||
} else if ((exc.statusCode ?? exc.status) === 403 || (exc.statusCode ?? exc.status) === 404 || (exc.statusCode ?? exc.status) === 502 || exc.message == "Internal Server Error") {
|
||||
} else if (exc.statusCode ?? exc.status) === 404 || (exc.statusCode ?? exc.status) === 502 || exc.message == "Internal Server Error") {
|
||||
this._sendError = new Error(`/join : room '${roomName}' not found`);
|
||||
} else if (exc.statusCode ?? exc.status) === 403) {
|
||||
this._sendError = new Error(`/join : you're not invited to join '${roomName}'`);
|
||||
} else {
|
||||
this._sendError = new Error("join syntax: /join <room-id>");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue