Merge branch 'develop' into t3chguy/remove_bluebird_1

This commit is contained in:
Michael Telatynski 2019-11-12 18:16:34 +00:00 committed by GitHub
commit 79ebb9091c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 1043 additions and 35 deletions

View file

@ -60,7 +60,8 @@ import AutoDiscoveryUtils from "../../utils/AutoDiscoveryUtils";
import DMRoomMap from '../../utils/DMRoomMap';
import { countRoomsWithNotif } from '../../RoomNotifs';
import { setTheme } from "../../theme";
import {defer} from "../../utils/promise";
import { storeRoomAliasInCache } from '../../RoomAliasCache';
import { defer } from "../../utils/promise";
// Disable warnings for now: we use deprecated bluebird functions
// and need to migrate, but they spam the console with warnings.
@ -867,7 +868,12 @@ export default createReactClass({
const room = MatrixClientPeg.get().getRoom(roomInfo.room_id);
if (room) {
const theAlias = Rooms.getDisplayAliasForRoom(room);
if (theAlias) presentedId = theAlias;
if (theAlias) {
presentedId = theAlias;
// Store display alias of the presented room in cache to speed future
// navigation.
storeRoomAliasInCache(theAlias, room.roomId);
}
// Store this as the ID of the last room accessed. This is so that we can
// persist which room is being stored across refreshes and browser quits.