From 5fe50775784451e591507143d094dca89fed4e85 Mon Sep 17 00:00:00 2001 From: Nikhil Ranjan Date: Thu, 12 Sep 2019 18:55:31 +0200 Subject: [PATCH] =?UTF-8?q?MM-18257=20Converting=20to=20structured=20loggi?= =?UTF-8?q?ng=20the=20file=20utils/i18n.=E2=80=A6=20(#12095)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- utils/i18n.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils/i18n.go b/utils/i18n.go index d04221168d..fcb722dc8a 100644 --- a/utils/i18n.go +++ b/utils/i18n.go @@ -67,7 +67,7 @@ func InitTranslationsWithDir(dir string) error { func GetTranslationsBySystemLocale() (i18n.TranslateFunc, error) { locale := *settings.DefaultServerLocale if _, ok := locales[locale]; !ok { - mlog.Error(fmt.Sprintf("Failed to load system translations for '%v' attempting to fall back to '%v'", locale, model.DEFAULT_LOCALE)) + mlog.Error("Failed to load system translations for", mlog.String("locale", locale), mlog.String("attempting to fall back to default locale", model.DEFAULT_LOCALE)) locale = model.DEFAULT_LOCALE } @@ -80,7 +80,7 @@ func GetTranslationsBySystemLocale() (i18n.TranslateFunc, error) { return nil, fmt.Errorf("Failed to load system translations") } - mlog.Info(fmt.Sprintf("Loaded system translations for '%v' from '%v'", locale, locales[locale])) + mlog.Info("Loaded system translations", mlog.String("for locale", locale), mlog.String("from locale", locales[locale])) return translations, nil }