]> source.dussan.org Git - gitea.git/commitdiff
Update docs and comments to remove macaron (#14491)
authorLunny Xiao <xiaolunwen@gmail.com>
Fri, 29 Jan 2021 15:35:30 +0000 (23:35 +0800)
committerGitHub <noreply@github.com>
Fri, 29 Jan 2021 15:35:30 +0000 (16:35 +0100)
29 files changed:
custom/conf/app.example.ini
docker/root/etc/templates/app.ini
docs/content/doc/advanced/config-cheat-sheet.en-us.md
docs/content/doc/advanced/environment-variables.en-us.md
docs/content/doc/advanced/environment-variables.zh-cn.md
docs/content/doc/advanced/logging-documentation.en-us.md
integrations/mssql.ini.tmpl
integrations/mysql.ini.tmpl
integrations/mysql8.ini.tmpl
integrations/oauth_test.go
integrations/pgsql.ini.tmpl
integrations/sqlite.ini.tmpl
modules/context/api.go
modules/context/org.go
modules/context/permission.go
modules/context/private.go
modules/context/repo.go
modules/log/log.go
modules/public/dynamic.go
modules/public/public.go
modules/public/static.go
modules/setting/log.go
modules/setting/setting.go
modules/translation/translation.go
options/locale/locale_en-US.ini
routers/admin/admin.go
routers/install.go
routers/routes/web.go
templates/admin/config.tmpl

index 8bc4a2c20475cf0e687a4ff3713e04a531471836..cec7e4255a20f6ce80cc1732608270ccf7513ffa 100644 (file)
@@ -863,8 +863,6 @@ ROOT_PATH =
 MODE = console
 ; Buffer length of the channel, keep it as it is if you don't know what it is.
 BUFFER_LEN = 10000
-REDIRECT_MACARON_LOG = false
-MACARON = file
 ; Either "Trace", "Debug", "Info", "Warn", "Error", "Critical", default is "Info"
 ROUTER_LOG_LEVEL = Info
 ROUTER = console
index 1a831a6d10eedc9688693814c9b67cc2e77fb0e1..c8a8cdc5f3883da53100cf06c9b949ece48ee76e 100644 (file)
@@ -47,8 +47,6 @@ PATH = /data/gitea/attachments
 [log]
 MODE = console
 LEVEL = info
-REDIRECT_MACARON_LOG = true
-MACARON = console
 ROUTER = console
 ROOT_PATH = /data/gitea/log
 
index 1d9326ad6ea7824bdc0b90f6b345d6c053052e33..9b5c4cbf2df7cd67f699b29772bf1dd18ad72342 100644 (file)
@@ -611,7 +611,7 @@ Default templates for project boards:
 - `STACKTRACE_LEVEL`: **None**: Default log level at which to log create stack traces. \[Trace, Debug, Info, Warn, Error, Critical, Fatal, None\]
 - `ROUTER_LOG_LEVEL`: **Info**: The log level that the router should log at. (If you are setting the access log, its recommended to place this at Debug.)
 - `ROUTER`: **console**: The mode or name of the log the router should log to. (If you set this to `,` it will log to default gitea logger.)
-NB: You must `REDIRECT_MACARON_LOG` and have `DISABLE_ROUTER_LOG` set to `false` for this option to take effect. Configure each mode in per mode log subsections `\[log.modename.router\]`.
+NB: You must have `DISABLE_ROUTER_LOG` set to `false` for this option to take effect. Configure each mode in per mode log subsections `\[log.modename.router\]`.
 - `ENABLE_ACCESS_LOG`: **false**: Creates an access.log in NCSA common log format, or as per the following template
 - `ACCESS`: **file**: Logging mode for the access logger, use a comma to separate values. Configure each mode in per mode log subsections `\[log.modename.access\]`. By default the file mode will log to `$ROOT_PATH/access.log`. (If you set this to `,` it will log to the default gitea logger.)
 - `ACCESS_LOG_TEMPLATE`: **`{{.Ctx.RemoteAddr}} - {{.Identity}} {{.Start.Format "[02/Jan/2006:15:04:05 -0700]" }} "{{.Ctx.Req.Method}} {{.Ctx.Req.URL.RequestURI}} {{.Ctx.Req.Proto}}" {{.ResponseWriter.Status}} {{.ResponseWriter.Size}} "{{.Ctx.Req.Referer}}\" \"{{.Ctx.Req.UserAgent}}"`**: Sets the template used to create the access log.
index deb195aeb88b4e0a9c6e842f35923095fe6b7088..288358f69dbe8c65b34cb299ce9240232b91ef11 100644 (file)
@@ -58,15 +58,6 @@ For documentation about each of the variables available, refer to the
 - `HOMEDRIVE`: Main drive path used to access the home directory (C:)
 - `HOMEPATH`: Home relative path in the given home drive path
 
-## Macaron (framework used by Gitea)
-
-- `HOST`: Host Macaron will listen on
-- `PORT`: Port Macaron will listen on
-- `MACARON_ENV`: global variable to provide special functionality for development environments
-  vs. production environments. If MACARON_ENV is set to "" or "development", then templates will
-  be recompiled on every request. For more performance, set the MACARON_ENV environment variable
-  to "production".
-
 ## Miscellaneous
 
 - `SKIP_MINWINSVC`: If set to 1, do not run as a service on Windows.
index 4b936a53faf33e7374278bba8e78af5326b13512..63ee4c69357f03f70e2658152861be0117d32b50 100644 (file)
@@ -50,13 +50,6 @@ GITEA_CUSTOM=/home/gitea/custom ./gitea web
   * `HOMEDRIVE`: 用于访问 home 目录的主驱动器路径(C盘)
   * `HOMEPATH`:在指定主驱动器下的 home 目录相对路径
 
-## Macaron(Gitea 使用的 web 框架)
-
-  * `HOST`:Macaron 监听的主机地址
-  * `PORT`:Macaron 监听的端口地址
-  * `MACARON_ENV`:为开发环境和生产环境提供特殊功能性配置的全局变量,当 MACARON_ENV 设置为 "" 或 "development"
-  时,每次请求都会重编译页面模板。为了提高性能表现,可将它设置为 "production"。
-
 ## Miscellaneous
 
   * `SKIP_MINWINSVC`:如果设置为 1,在 Windows 上不会以 service 的形式运行。
index 195820329d26f266bb6ecc98e240a73aa233165c..73a5e0eae15dd9b7dfda5c1939e20fbd3c5fa8dc 100644 (file)
@@ -27,7 +27,6 @@ The fundamental thing to be aware of in Gitea is that there are several
 log groups:
 
 - The "Default" logger
-- The Macaron logger
 - The Router logger
 - The Access logger
 - The XORM logger
@@ -74,8 +73,7 @@ You can disable Router log by setting `DISABLE_ROUTER_LOG`.
 You can configure the outputs of this
 router log by setting the `ROUTER` value in the `[log]` section of the
 configuration. `ROUTER` will default to `console` if unset. The Gitea
-Router logs the same data as the Macaron log but has slightly different
-coloring. It logs at the `Info` level by default, but this can be
+Router logs at the `Info` level by default, but this can be
 changed if desired by setting the `ROUTER_LOG_LEVEL` value.
 
 Please note, setting the `LEVEL` of this logger to a level above
@@ -182,7 +180,7 @@ Certain configuration is common to all modes of log output:
 - `STACKTRACE_LEVEL` is the lowest level that this output will print
   a stacktrace. This value is inherited.
 - `MODE` is the mode of the log output. It will default to the sublogger
-  name. Thus `[log.console.macaron]` will default to `MODE = console`.
+  name. Thus `[log.console.router]` will default to `MODE = console`.
 - `COLORIZE` will default to `true` for `console` as
   described, otherwise it will default to `false`.
 
@@ -280,8 +278,6 @@ LOG_SQL = false ; SQL logs are rarely helpful unless we specifically ask for the
 [log]
 MODE = console
 LEVEL = debug ; please set the level to debug when we are debugging a problem
-REDIRECT_MACARON_LOG = true
-MACARON = console
 ROUTER = console
 COLORIZE = false ; this can be true if you can strip out the ansi coloring
 ```
@@ -314,7 +310,6 @@ ROOT_PATH = %(GITEA_WORK_DIR)/log
 MODE = console
 LEVEL = Info
 STACKTRACE_LEVEL = None
-REDIRECT_MACARON_LOG = false
 ENABLE_ACCESS_LOG = false
 ENABLE_XORM_LOG = true
 XORM = ,
@@ -345,7 +340,7 @@ recommended that pausing only done for a very short period of time.
 ## Adding and removing logging whilst Gitea is running
 
 It is possible to add and remove logging whilst Gitea is running using the `gitea manager logging add` and `remove` subcommands.
-This functionality can only adjust running log systems and cannot be used to start the access, macaron or router loggers if they
+This functionality can only adjust running log systems and cannot be used to start the access or router loggers if they
 were not already initialised. If you wish to start these systems you are advised to adjust the app.ini and (gracefully) restart
 the Gitea service.
 
index 44c0a7eed9fbb23eeae740e2e683810959fd9c8b..a9a934c56814bc58b37b6aec0bc254448984e4a4 100644 (file)
@@ -78,9 +78,7 @@ PROVIDER_CONFIG = integrations/gitea-integration-mssql/data/sessions
 [log]
 MODE                 = test,file
 ROOT_PATH            = mssql-log
-REDIRECT_MACARON_LOG = true
 ROUTER               = ,
-MACARON              = ,
 XORM                 = file
 
 [log.test]
index 2b044498ebd4e71faeb61335659717ffa52045b7..f8abd3ffeb7759343dc27dc114b2e6a34de3ac18 100644 (file)
@@ -97,9 +97,7 @@ PROVIDER_CONFIG = integrations/gitea-integration-mysql/data/sessions
 [log]
 MODE                 = test,file
 ROOT_PATH            = mysql-log
-REDIRECT_MACARON_LOG = true
 ROUTER               = ,
-MACARON              = ,
 XORM                 = file
 
 [log.test]
index 798ab7852acaed032fd11c35cccedda82b7a3933..cccede5b20dfbb98f5c2b1ca60bb04f12aee65a9 100644 (file)
@@ -70,9 +70,7 @@ PROVIDER_CONFIG = data/sessions-mysql8
 [log]
 MODE                 = test,file
 ROOT_PATH            = mysql8-log
-REDIRECT_MACARON_LOG = true
 ROUTER               = ,
-MACARON              = ,
 XORM                 = file
 
 [log.test]
index a9e48b061f2b72158d410a8c5ef886c3f09eab41..e74ff28cadf142ebf2d0e9a9642e734b881811a9 100644 (file)
@@ -235,7 +235,7 @@ func TestRefreshTokenInvalidation(t *testing.T) {
                "redirect_uri":  "a",
                "refresh_token": parsed.RefreshToken,
        })
-       // tip: Why this changed, because macaron will set req.Body back when consume the req but chi will not.
+
        bs, err := ioutil.ReadAll(refreshReq.Body)
        assert.NoError(t, err)
 
index 5f082f04e1a76e7e0cfb18d2d98722502729cb52..a8742268db30f25579ee9f2ef69d0dead1f57dd6 100644 (file)
@@ -79,9 +79,7 @@ PROVIDER_CONFIG = integrations/gitea-integration-pgsql/data/sessions
 [log]
 MODE                 = test,file
 ROOT_PATH            = pgsql-log
-REDIRECT_MACARON_LOG = true
 ROUTER               = ,
-MACARON              = ,
 XORM                 = file
 
 [log.test]
index 5ed096b0a3896ac0efd148e2ba0a718100e02a93..9d78d0c56bc6a59af6191c2024982039b54869bc 100644 (file)
@@ -75,9 +75,7 @@ PROVIDER_CONFIG = integrations/gitea-integration-sqlite/data/sessions
 [log]
 MODE                 = test,file
 ROOT_PATH            = sqlite-log
-REDIRECT_MACARON_LOG = true
 ROUTER               = ,
-MACARON              = ,
 XORM                 = file
 
 [log.test]
index cf6dc265cd6fbc11e91e7cecfd739f61ccae4ab4..aab6905fd152c81867441c7ff90219c8efeb073b 100644 (file)
@@ -23,7 +23,7 @@ import (
        "gitea.com/go-chi/session"
 )
 
-// APIContext is a specific macaron context for API service
+// APIContext is a specific context for API service
 type APIContext struct {
        *Context
        Org *APIOrganization
@@ -217,7 +217,7 @@ func (ctx *APIContext) CheckForOTP() {
        }
 }
 
-// APIContexter returns apicontext as macaron middleware
+// APIContexter returns apicontext as middleware
 func APIContexter() func(http.Handler) http.Handler {
        var csrfOpts = getCsrfOpts()
 
index 83d385a1e934b558c72309990cf17bf9e2052e74..5148cc4a6ca8d97296be62044677d2e21693ffc5 100644 (file)
@@ -170,7 +170,7 @@ func HandleOrgAssignment(ctx *Context, args ...bool) {
        }
 }
 
-// OrgAssignment returns a macaron middleware to handle organization assignment
+// OrgAssignment returns a middleware to handle organization assignment
 func OrgAssignment(args ...bool) func(ctx *Context) {
        return func(ctx *Context) {
                HandleOrgAssignment(ctx, args...)
index 6fb8237e22cbe42ccf7ec1c3e383785115df080d..b9cdf93de2dbf3bbee88121815c2cac964a20c21 100644 (file)
@@ -9,7 +9,7 @@ import (
        "code.gitea.io/gitea/modules/log"
 )
 
-// RequireRepoAdmin returns a macaron middleware for requiring repository admin permission
+// RequireRepoAdmin returns a middleware for requiring repository admin permission
 func RequireRepoAdmin() func(ctx *Context) {
        return func(ctx *Context) {
                if !ctx.IsSigned || !ctx.Repo.IsAdmin() {
@@ -19,7 +19,7 @@ func RequireRepoAdmin() func(ctx *Context) {
        }
 }
 
-// RequireRepoWriter returns a macaron middleware for requiring repository write to the specify unitType
+// RequireRepoWriter returns a middleware for requiring repository write to the specify unitType
 func RequireRepoWriter(unitType models.UnitType) func(ctx *Context) {
        return func(ctx *Context) {
                if !ctx.Repo.CanWrite(unitType) {
@@ -29,7 +29,7 @@ func RequireRepoWriter(unitType models.UnitType) func(ctx *Context) {
        }
 }
 
-// RequireRepoWriterOr returns a macaron middleware for requiring repository write to one of the unit permission
+// RequireRepoWriterOr returns a middleware for requiring repository write to one of the unit permission
 func RequireRepoWriterOr(unitTypes ...models.UnitType) func(ctx *Context) {
        return func(ctx *Context) {
                for _, unitType := range unitTypes {
@@ -41,7 +41,7 @@ func RequireRepoWriterOr(unitTypes ...models.UnitType) func(ctx *Context) {
        }
 }
 
-// RequireRepoReader returns a macaron middleware for requiring repository read to the specify unitType
+// RequireRepoReader returns a middleware for requiring repository read to the specify unitType
 func RequireRepoReader(unitType models.UnitType) func(ctx *Context) {
        return func(ctx *Context) {
                if !ctx.Repo.CanRead(unitType) {
@@ -67,7 +67,7 @@ func RequireRepoReader(unitType models.UnitType) func(ctx *Context) {
        }
 }
 
-// RequireRepoReaderOr returns a macaron middleware for requiring repository write to one of the unit permission
+// RequireRepoReaderOr returns a middleware for requiring repository write to one of the unit permission
 func RequireRepoReaderOr(unitTypes ...models.UnitType) func(ctx *Context) {
        return func(ctx *Context) {
                for _, unitType := range unitTypes {
index a246100050845976d27dafb5484c39ef3e93f3d8..dfefa1d2f0192d0bdebd8f76fa0a82b6a0ad70f4 100644 (file)
@@ -28,7 +28,7 @@ func GetPrivateContext(req *http.Request) *PrivateContext {
        return req.Context().Value(privateContextKey).(*PrivateContext)
 }
 
-// PrivateContexter returns apicontext as macaron middleware
+// PrivateContexter returns apicontext as middleware
 func PrivateContexter() func(http.Handler) http.Handler {
        return func(next http.Handler) http.Handler {
                return http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) {
index 79192267fbf4843ff98f75ad4dded5837a815a2e..13037f4625d318f5716cb9e1b28ae308ba1b5c71 100644 (file)
@@ -373,7 +373,7 @@ func repoAssignment(ctx *Context, repo *models.Repository) {
        ctx.Data["IsEmptyRepo"] = ctx.Repo.Repository.IsEmpty
 }
 
-// RepoIDAssignment returns a macaron handler which assigns the repo to the context.
+// RepoIDAssignment returns a handler which assigns the repo to the context.
 func RepoIDAssignment() func(ctx *Context) {
        return func(ctx *Context) {
                repoID := ctx.ParamsInt64(":repoid")
@@ -393,7 +393,7 @@ func RepoIDAssignment() func(ctx *Context) {
        }
 }
 
-// RepoAssignment returns a macaron to handle repository assignment
+// RepoAssignment returns a middleware to handle repository assignment
 func RepoAssignment() func(http.Handler) http.Handler {
        return func(next http.Handler) http.Handler {
                return http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) {
@@ -849,7 +849,7 @@ func GitHookService() func(ctx *Context) {
        }
 }
 
-// UnitTypes returns a macaron middleware to set unit types to context variables.
+// UnitTypes returns a middleware to set unit types to context variables.
 func UnitTypes() func(ctx *Context) {
        return func(ctx *Context) {
                ctx.Data["UnitTypeCode"] = models.UnitTypeCode
index 16a6efb75b9a8fc78afcce615de1548221876a9a..cae24f53d87f22f0c19ac293ab8ffa25e7451959 100644 (file)
@@ -267,7 +267,7 @@ func NewLoggerAsWriter(level string, ourLoggers ...*MultiChannelledLogger) *Logg
        return l
 }
 
-// Write implements the io.Writer interface to allow spoofing of macaron
+// Write implements the io.Writer interface to allow spoofing of chi
 func (l *LoggerAsWriter) Write(p []byte) (int, error) {
        for _, logger := range l.ourLoggers {
                // Skip = 3 because this presumes that we have been called by log.Println()
index f634c598a3f1af4d7ea1f10f5be2e758b7b37d8e..a57b6363692932fc108f589532c959222451872e 100644 (file)
@@ -13,7 +13,7 @@ import (
        "time"
 )
 
-// Static implements the macaron static handler for serving assets.
+// Static implements the static handler for serving assets.
 func Static(opts *Options) func(next http.Handler) http.Handler {
        return opts.staticHandler(opts.Directory)
 }
index 6417c91f1a6f0d9042cae605447fef215bc5029e..6695944bd65a0eb24b23c86a6c28c5c16ec05e97 100644 (file)
@@ -15,7 +15,7 @@ import (
        "code.gitea.io/gitea/modules/setting"
 )
 
-// Options represents the available options to configure the macaron handler.
+// Options represents the available options to configure the handler.
 type Options struct {
        Directory   string
        IndexFile   string
@@ -34,7 +34,7 @@ var KnownPublicEntries = []string{
        "favicon.ico",
 }
 
-// Custom implements the macaron static handler for serving custom assets.
+// Custom implements the static handler for serving custom assets.
 func Custom(opts *Options) func(next http.Handler) http.Handler {
        return opts.staticHandler(path.Join(setting.CustomPath, "public"))
 }
index c4dd7a1eca750f65b35cdc0e1228169a6adc1365..36cfdbe44f32ed5e3ad1c45d8e63cb30a95e89d5 100644 (file)
@@ -20,7 +20,7 @@ import (
        "code.gitea.io/gitea/modules/log"
 )
 
-// Static implements the macaron static handler for serving assets.
+// Static implements the static handler for serving assets.
 func Static(opts *Options) func(next http.Handler) http.Handler {
        opts.FileSystem = Assets
        // we don't need to pass the directory, because the directory var is only
index daa449a5ca76c84efe795b355724063857e958a4..9fe2d5bda380e5026bea1e0dfb3dcbb979b2077c 100644 (file)
@@ -273,7 +273,7 @@ func newRouterLogService() {
        // Allow [log]  DISABLE_ROUTER_LOG to override [server] DISABLE_ROUTER_LOG
        DisableRouterLog = Cfg.Section("log").Key("DISABLE_ROUTER_LOG").MustBool(DisableRouterLog)
 
-       if !DisableRouterLog && RedirectMacaronLog {
+       if !DisableRouterLog {
                options := newDefaultLogOptions()
                options.filename = filepath.Join(LogRootPath, "router.log")
                options.flags = "date,time" // For the router we don't want any prefixed flags
index f69dd11cebcf319b2bd2ea2b2144dbe9c17450ac..dd38f5be45dd2557dd68f2ef246c4b70c39a6cd6 100644 (file)
@@ -288,7 +288,6 @@ var (
        LogLevel           string
        StacktraceLogLevel string
        LogRootPath        string
-       RedirectMacaronLog bool
        DisableRouterLog   bool
        RouterLogLevel     log.Level
        RouterLogMode      string
@@ -539,7 +538,6 @@ func NewContext() {
        StacktraceLogLevel = getStacktraceLogLevel(Cfg.Section("log"), "STACKTRACE_LEVEL", "None")
        LogRootPath = Cfg.Section("log").Key("ROOT_PATH").MustString(path.Join(AppWorkPath, "log"))
        forcePathSeparator(LogRootPath)
-       RedirectMacaronLog = Cfg.Section("log").Key("REDIRECT_MACARON_LOG").MustBool(false)
        RouterLogLevel = log.FromString(Cfg.Section("log").Key("ROUTER_LOG_LEVEL").MustString("Info"))
 
        sec := Cfg.Section("server")
index 94a93a40ae2a3ab3b36d8ef96ae299a01c49a05c..28ff6a5db1510ebb526454a75ed1e26f41f5cea3 100644 (file)
@@ -49,7 +49,6 @@ func InitLocales() {
                }
        }
 
-       // These codes will be used once macaron removed
        tags := make([]language.Tag, len(setting.Langs))
        for i, lang := range setting.Langs {
                tags[i] = language.Raw.Make(lang)
index a7dae87cd892b5f809eac6a973ae120f11dad251..a4b677e43baf75b04dbeb4c40087fe3aaa902fab 100644 (file)
@@ -2402,7 +2402,6 @@ config.git_gc_timeout = GC Operation Timeout
 
 config.log_config = Log Configuration
 config.log_mode = Log Mode
-config.macaron_log_mode = Macaron Log Mode
 config.own_named_logger = Named Logger
 config.routes_to_default_logger = Routes To Default Logger
 config.go_log = Uses Go Log (redirected to default)
index 250bc5da5ec393ad181c2c268af503217fc67fe0..c8f9d8b35ba16558da9468481204a4c5c7d6d0b8 100644 (file)
@@ -308,7 +308,6 @@ func Config(ctx *context.Context) {
 
        ctx.Data["EnvVars"] = envVars
        ctx.Data["Loggers"] = setting.GetLogDescriptions()
-       ctx.Data["RedirectMacaronLog"] = setting.RedirectMacaronLog
        ctx.Data["EnableAccessLog"] = setting.EnableAccessLog
        ctx.Data["AccessLogTemplate"] = setting.AccessLogTemplate
        ctx.Data["DisableRouterLog"] = setting.DisableRouterLog
index 5dcd1d48a399d3caa022f06f3bfad00540e7211e..da2631931ebcbaa3665a33020beacece925d6d7a 100644 (file)
@@ -371,8 +371,6 @@ func InstallPost(ctx *context.Context) {
        cfg.Section("log").Key("MODE").SetValue("console")
        cfg.Section("log").Key("LEVEL").SetValue(setting.LogLevel)
        cfg.Section("log").Key("ROOT_PATH").SetValue(form.LogRootPath)
-       cfg.Section("log").Key("REDIRECT_MACARON_LOG").SetValue("true")
-       cfg.Section("log").Key("MACARON").SetValue("console")
        cfg.Section("log").Key("ROUTER").SetValue("console")
 
        cfg.Section("security").Key("INSTALL_LOCK").SetValue("true")
index 3fecb4dbbe05b88419939a56a4925ab32f33722b..03555e3d547347b2480fa42f16350d6f6a0a20dc 100644 (file)
@@ -215,7 +215,7 @@ func WebRoutes() *web.Route {
        return r
 }
 
-// RegisterRoutes routes routes to Macaron
+// RegisterRoutes register routes
 func RegisterRoutes(m *web.Route) {
        reqSignIn := context.Toggle(&context.ToggleOptions{SignInRequired: true})
        ignSignIn := context.Toggle(&context.ToggleOptions{SignInRequired: setting.Service.RequireSignInView})
index aa6a9b793b23b9ae4a3f2b2d5cfe09cd227df9f1..a3c55b2b18c288b44135c03fac3c60bd3f73f467 100644 (file)
                                {{if .DisableRouterLog}}
                                        <dd>{{$.i18n.Tr "admin.config.disabled_logger"}}</dd>
                                {{else}}
-                                       {{if .RedirectMacaronLog}}
-                                               {{if .Loggers.router.SubLogDescriptions}}
-                                                       <dd>{{$.i18n.Tr "admin.config.own_named_logger"}}</dd>
-                                                       {{range .Loggers.router.SubLogDescriptions}}
-                                                               <dt>{{$.i18n.Tr "admin.config.log_mode"}}</dt>
-                                                               <dd>{{.Name}} ({{.Provider}})</dd>
-                                                               <dt>{{$.i18n.Tr "admin.config.log_config"}}</dt>
-                                                               <dd><pre>{{.Config | JsonPrettyPrint}}</pre></dd>
-                                                       {{end}}
-                                               {{else}}
-                                                       <dd>{{$.i18n.Tr "admin.config.routes_to_default_logger"}}</dd>
+                                       {{if .Loggers.router.SubLogDescriptions}}
+                                               <dd>{{$.i18n.Tr "admin.config.own_named_logger"}}</dd>
+                                               {{range .Loggers.router.SubLogDescriptions}}
+                                                       <dt>{{$.i18n.Tr "admin.config.log_mode"}}</dt>
+                                                       <dd>{{.Name}} ({{.Provider}})</dd>
+                                                       <dt>{{$.i18n.Tr "admin.config.log_config"}}</dt>
+                                                       <dd><pre>{{.Config | JsonPrettyPrint}}</pre></dd>
                                                {{end}}
                                        {{else}}
-                                               <dd>{{$.i18n.Tr "admin.config.go_log"}}</dd>
+                                               <dd>{{$.i18n.Tr "admin.config.routes_to_default_logger"}}</dd>
                                        {{end}}
                                {{end}}
                                <div class="ui divider"></div>