From dd9ad10d705fdbd7fbfa7323e6560b69021a2950 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Espino?= Date: Mon, 8 Jan 2018 19:13:24 +0100 Subject: [PLT-6936] Translate AppError.Message automatically by default (#8063) --- app/app.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/app.go') diff --git a/app/app.go b/app/app.go index 4813926e2..8aa894b9b 100644 --- a/app/app.go +++ b/app/app.go @@ -101,6 +101,7 @@ func New(options ...Option) *App { if utils.T == nil { utils.TranslationsPreInit() } + model.AppErrorInit(utils.T) utils.LoadGlobalConfig(app.configFile) utils.InitTranslations(utils.Cfg.LocalizationSettings) @@ -472,7 +473,6 @@ func (a *App) HTTPClient(trustURLs bool) *http.Client { func (a *App) Handle404(w http.ResponseWriter, r *http.Request) { err := model.NewAppError("Handle404", "api.context.404.app_error", nil, "", http.StatusNotFound) - err.Translate(utils.T) l4g.Debug("%v: code=404 ip=%v", r.URL.Path, utils.GetIpAddress(r)) -- cgit v1.2.3-1-g7c22