summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2016-01-29 08:38:24 -0500
committerChristopher Speller <crspeller@gmail.com>2016-01-29 08:38:24 -0500
commit66af7a8337897567133c31d7ae71d0538524fca0 (patch)
tree8db7b968699a683d7531155a53830de4c71ba5e2 /web
parente2238fcd51347c1f93ba8a13fc34ee7d720e133a (diff)
parent6cba0353c936fbb2cac8b32b893def75c28ae81e (diff)
downloadchat-66af7a8337897567133c31d7ae71d0538524fca0.tar.gz
chat-66af7a8337897567133c31d7ae71d0538524fca0.tar.bz2
chat-66af7a8337897567133c31d7ae71d0538524fca0.zip
Merge pull request #2013 from mattermost/plt-1749
PLT-1749 Return channel type in new post websocket events
Diffstat (limited to 'web')
-rw-r--r--web/react/stores/socket_store.jsx3
1 files changed, 2 insertions, 1 deletions
diff --git a/web/react/stores/socket_store.jsx b/web/react/stores/socket_store.jsx
index f1fade305..736b0ca27 100644
--- a/web/react/stores/socket_store.jsx
+++ b/web/react/stores/socket_store.jsx
@@ -176,6 +176,7 @@ function handleNewPostEvent(msg) {
mentions = JSON.parse(msg.props.mentions);
}
+ const channelType = msgProps.channel_type;
const channel = ChannelStore.get(msg.channel_id);
const user = UserStore.getCurrentUser();
const member = ChannelStore.getMember(msg.channel_id);
@@ -187,7 +188,7 @@ function handleNewPostEvent(msg) {
if (notifyLevel === 'none') {
return;
- } else if (notifyLevel === 'mention' && mentions.indexOf(user.id) === -1 && channel.type !== 'D') {
+ } else if (notifyLevel === 'mention' && mentions.indexOf(user.id) === -1 && channelType !== Constants.DM_CHANNEL) {
return;
}