Mono repo -> Master (#22553)
Combines the following repositories into one: https://github.com/mattermost/mattermost-server https://github.com/mattermost/mattermost-webapp https://github.com/mattermost/focalboard https://github.com/mattermost/mattermost-plugin-playbooks
Этот коммит содержится в:
27
server/channels/wsapi/api.go
Обычный файл
27
server/channels/wsapi/api.go
Обычный файл
@@ -0,0 +1,27 @@
|
||||
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
||||
// See LICENSE.txt for license information.
|
||||
|
||||
package wsapi
|
||||
|
||||
import (
|
||||
"github.com/mattermost/mattermost-server/v6/server/channels/app"
|
||||
"github.com/mattermost/mattermost-server/v6/server/channels/app/platform"
|
||||
)
|
||||
|
||||
type API struct {
|
||||
App *app.App
|
||||
Router *platform.WebSocketRouter
|
||||
}
|
||||
|
||||
func Init(s *app.Server) {
|
||||
a := app.New(app.ServerConnector(s.Channels()))
|
||||
router := s.Platform().WebSocketRouter
|
||||
api := &API{
|
||||
App: a,
|
||||
Router: router,
|
||||
}
|
||||
|
||||
api.InitUser()
|
||||
api.InitSystem()
|
||||
api.InitStatus()
|
||||
}
|
||||
Ссылка в новой задаче
Block a user