From 07f0df6af428a56a4abedde841a0813e2802cd2b Mon Sep 17 00:00:00 2001
From: hmhealey <harrisonmhealey@gmail.com>
Date: Wed, 2 Dec 2015 09:21:58 -0500
Subject: Moved action creation for suggestions

---
 web/react/components/suggestion/suggestion_list.jsx | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

(limited to 'web/react/components/suggestion/suggestion_list.jsx')

diff --git a/web/react/components/suggestion/suggestion_list.jsx b/web/react/components/suggestion/suggestion_list.jsx
index cd75f36c5..290e0eec6 100644
--- a/web/react/components/suggestion/suggestion_list.jsx
+++ b/web/react/components/suggestion/suggestion_list.jsx
@@ -1,8 +1,8 @@
 // Copyright (c) 2015 Mattermost, Inc. All Rights Reserved.
 // See License.txt for license information.
 
-import AppDispatcher from '../../dispatcher/app_dispatcher.jsx';
 import Constants from '../../utils/constants.jsx';
+import * as EventHelpers from '../../dispatcher/event_helpers.jsx';
 import SuggestionStore from '../../stores/suggestion_store.jsx';
 
 export default class SuggestionList extends React.Component {
@@ -37,11 +37,7 @@ export default class SuggestionList extends React.Component {
     }
 
     handleItemClick(term, e) {
-        AppDispatcher.handleViewAction({
-            type: Constants.ActionTypes.SUGGESTION_COMPLETE_WORD,
-            id: this.props.suggestionId,
-            term
-        });
+        EventHelpers.emitCompleteWordSuggestion(this.props.suggestionId, term);
 
         e.preventDefault();
     }
-- 
cgit v1.2.3-1-g7c22

