Check if LHS DM list needs updating on channel switch and channel members fetch (#5861)

Этот коммит содержится в:
Joram Wilander
2017-03-24 16:46:39 -04:00
коммит произвёл Corey Hulen
родитель 69fb47b88b
Коммит 4dc03613b4
2 изменённых файлов: 4 добавлений и 1 удалений

Просмотреть файл

@@ -65,6 +65,8 @@ export function emitChannelClickEvent(channel) {
BrowserStore.setGlobalItem(chan.team_id, chan.id);
loadProfilesForSidebar();
AppDispatcher.handleViewAction({
type: ActionTypes.CLICK_CHANNEL,
name: chan.name,

Просмотреть файл

@@ -16,6 +16,7 @@ import PostStore from 'stores/post_store.jsx';
import * as GlobalActions from 'actions/global_actions.jsx';
import {startPeriodicStatusUpdates, stopPeriodicStatusUpdates} from 'actions/status_actions.jsx';
import {startPeriodicSync, stopPeriodicSync} from 'actions/websocket_actions.jsx';
import {loadProfilesForSidebar} from 'actions/user_actions.jsx';
import Constants from 'utils/constants.jsx';
const TutorialSteps = Constants.TutorialSteps;
@@ -108,7 +109,7 @@ export default class NeedsTeam extends React.Component {
window.isActive = true;
if (new Date().getTime() - this.blurTime > UNREAD_CHECK_TIME_MILLISECONDS) {
AsyncClient.getMyChannelMembers();
AsyncClient.getMyChannelMembers().then(loadProfilesForSidebar);
}
});