summaryrefslogtreecommitdiffstats
path: root/web/react/components/search_results.jsx
diff options
context:
space:
mode:
authornickago <ngonella@calpoly.edu>2015-07-01 12:41:36 -0700
committernickago <ngonella@calpoly.edu>2015-07-01 12:41:36 -0700
commitfd310e382a2cc1a9779ef28dee7fea9476bb425f (patch)
tree403e6ec6d8ccbe5f0742f2e9faddea71068f9745 /web/react/components/search_results.jsx
parent5e204030ffe91aaab090a26547185017edf1d2e1 (diff)
downloadchat-fd310e382a2cc1a9779ef28dee7fea9476bb425f.tar.gz
chat-fd310e382a2cc1a9779ef28dee7fea9476bb425f.tar.bz2
chat-fd310e382a2cc1a9779ef28dee7fea9476bb425f.zip
Finally fixed the git weirdness
Diffstat (limited to 'web/react/components/search_results.jsx')
-rw-r--r--web/react/components/search_results.jsx6
1 files changed, 6 insertions, 0 deletions
diff --git a/web/react/components/search_results.jsx b/web/react/components/search_results.jsx
index 51aefd3b8..15c2b37a2 100644
--- a/web/react/components/search_results.jsx
+++ b/web/react/components/search_results.jsx
@@ -43,6 +43,7 @@ SearchItem = React.createClass({
e.preventDefault();
var self = this;
+
client.getPost(
this.props.post.channel_id,
this.props.post.id,
@@ -64,6 +65,11 @@ SearchItem = React.createClass({
dispatchError(err, "getPost");
}
);
+
+ var postChannel = ChannelStore.get(this.props.post.channel_id);
+ var teammate = postChannel.type === 'D' ? utils.getDirectTeammate(this.props.post.channel_id).username : "";
+
+ utils.switchChannel(postChannel,teammate);
},
render: function() {