When removed from a channel, user is sent back to town square and that

channel is removed from their sidebar
Этот коммит содержится в:
nickago
2015-07-13 13:18:50 -07:00
родитель 85ff151b71
Коммит c9459feb59
3 изменённых файлов: 13 добавлений и 0 удалений

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

@@ -197,6 +197,14 @@ module.exports = React.createClass({
if (UserStore.getCurrentId() === msg.user_id) {
AsyncClient.getChannels(true);
}
} else if(msg.action === "user_removed") {
if(msg.user_id === UserStore.getCurrentId()) {
AsyncClient.getChannels(true);
if(msg.props.channel_id === ChannelStore.getCurrentId()) {
window.location.reload();
}
}
}
},
updateTitle: function() {