From 8230b49014481154af1c6c9c41944010f0fbec50 Mon Sep 17 00:00:00 2001 From: nickago Date: Fri, 21 Aug 2015 08:41:36 -0700 Subject: remove search term after the RHS is closed --- web/react/components/search_bar.jsx | 7 +++++++ web/react/components/search_results.jsx | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/web/react/components/search_bar.jsx b/web/react/components/search_bar.jsx index e39cf5d46..b11b39e9e 100644 --- a/web/react/components/search_bar.jsx +++ b/web/react/components/search_bar.jsx @@ -47,6 +47,13 @@ module.exports = React.createClass({ results: null }); + AppDispatcher.handleServerAction({ + type: ActionTypes.RECIEVED_SEARCH_TERM, + term: null, + do_search: false, + is_mention_search: false + }); + AppDispatcher.handleServerAction({ type: ActionTypes.RECIEVED_POST_SELECTED, results: null diff --git a/web/react/components/search_results.jsx b/web/react/components/search_results.jsx index 643ad112b..b1efd7685 100644 --- a/web/react/components/search_results.jsx +++ b/web/react/components/search_results.jsx @@ -23,6 +23,13 @@ var RhsHeaderSearch = React.createClass({ results: null }); + AppDispatcher.handleServerAction({ + type: ActionTypes.RECIEVED_SEARCH_TERM, + term: null, + do_search: false, + is_mention_search: false + }); + AppDispatcher.handleServerAction({ type: ActionTypes.RECIEVED_POST_SELECTED, results: null -- cgit v1.2.3-1-g7c22