Merge pull request #1793 from thecodingmachine/fix_redirect_lastroomurl
Fix redirect error after invalid token
This commit is contained in:
commit
462cb53101
@ -183,14 +183,14 @@ class ConnectionManager {
|
||||
window.location.hash;
|
||||
}
|
||||
|
||||
//Set last room visited! (connected or nor, must to be saved in localstorage and cache API)
|
||||
//use href to keep # value
|
||||
await localUserStore.setLastRoomUrl(new URL(roomPath).href);
|
||||
|
||||
//get detail map for anonymous login and set texture in local storage
|
||||
//before set token of user we must load room and all information. For example the mandatory authentication could be require on current room
|
||||
this._currentRoom = await Room.createRoom(new URL(roomPath));
|
||||
|
||||
//Set last room visited! (connected or nor, must to be saved in localstorage and cache API)
|
||||
//use href to keep # value
|
||||
await localUserStore.setLastRoomUrl(this._currentRoom.href);
|
||||
|
||||
//todo: add here some kind of warning if authToken has expired.
|
||||
if (!this.authToken && !this._currentRoom.authenticationMandatory) {
|
||||
await this.anonymousLogin();
|
||||
|
Loading…
Reference in New Issue
Block a user