From 97558f6a6ec4c53fa69035fb430ead209d9c222d Mon Sep 17 00:00:00 2001 From: Joram Wilander Date: Fri, 13 Jan 2017 13:53:37 -0500 Subject: PLT-4938 Add app package and move logic over from api package (#4931) * Add app package and move logic over from api package * Change app package functions to return errors * Move non-api tests into app package * Fix merge --- api/general.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'api/general.go') diff --git a/api/general.go b/api/general.go index 24855b821..5c8e45082 100644 --- a/api/general.go +++ b/api/general.go @@ -10,6 +10,7 @@ import ( l4g "github.com/alecthomas/log4go" + "github.com/mattermost/platform/app" "github.com/mattermost/platform/model" "github.com/mattermost/platform/utils" ) @@ -21,7 +22,7 @@ func InitGeneral() { BaseRoutes.General.Handle("/log_client", ApiAppHandler(logClient)).Methods("POST") BaseRoutes.General.Handle("/ping", ApiAppHandler(ping)).Methods("GET") - BaseRoutes.WebSocket.Handle("ping", ApiWebSocketHandler(webSocketPing)) + app.Srv.WebSocketRouter.Handle("ping", ApiWebSocketHandler(webSocketPing)) } func getClientConfig(c *Context, w http.ResponseWriter, r *http.Request) { -- cgit v1.2.3-1-g7c22