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
Этот коммит содержится в:
29
server/boards/app/initialize.go
Обычный файл
29
server/boards/app/initialize.go
Обычный файл
@@ -0,0 +1,29 @@
|
||||
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
||||
// See LICENSE.txt for license information.
|
||||
|
||||
package app
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/mattermost/mattermost-server/v6/server/platform/shared/mlog"
|
||||
)
|
||||
|
||||
// initialize is called when the App is first created.
|
||||
func (a *App) initialize(skipTemplateInit bool) {
|
||||
if !skipTemplateInit {
|
||||
if err := a.InitTemplates(); err != nil {
|
||||
a.logger.Error(`InitializeTemplates failed`, mlog.Err(err))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (a *App) Shutdown() {
|
||||
if a.blockChangeNotifier != nil {
|
||||
ctx, cancel := context.WithTimeout(context.Background(), blockChangeNotifierShutdownTimeout)
|
||||
defer cancel()
|
||||
if !a.blockChangeNotifier.Shutdown(ctx) {
|
||||
a.logger.Warn("blockChangeNotifier shutdown timed out")
|
||||
}
|
||||
}
|
||||
}
|
||||
Ссылка в новой задаче
Block a user