From fba49d1b809077bc4b8e4d8b303e38295151758a Mon Sep 17 00:00:00 2001 From: Joram Wilander Date: Tue, 3 Jan 2017 12:38:51 -0500 Subject: Fix console error when logging in with non-english language (#4941) --- webapp/actions/global_actions.jsx | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'webapp/actions') diff --git a/webapp/actions/global_actions.jsx b/webapp/actions/global_actions.jsx index 9dd3eff35..c6b796983 100644 --- a/webapp/actions/global_actions.jsx +++ b/webapp/actions/global_actions.jsx @@ -190,15 +190,11 @@ export function emitPostFocusEvent(postId, onSuccess) { } export function emitCloseRightHandSide() { - AppDispatcher.handleServerAction({ - type: ActionTypes.RECEIVED_SEARCH, - results: null - }); + SearchStore.storeSearchResults(null, false, false); + SearchStore.emitSearchChange(); - AppDispatcher.handleServerAction({ - type: ActionTypes.RECEIVED_POST_SELECTED, - postId: null - }); + PostStore.storeSelectedPostId(null); + PostStore.emitSelectedPostChange(false, false); } export function emitPostFocusRightHandSideFromSearch(post, isMentionSearch) { -- cgit v1.2.3-1-g7c22