diff --git a/routers/routes/web.go b/routers/routes/web.go index 24336185817f0..6b6322f048fc7 100644 --- a/routers/routes/web.go +++ b/routers/routes/web.go @@ -101,7 +101,6 @@ func NormalRoutes() *web.Route { for _, middle := range commonMiddlewares() { r.Use(middle) } - r.Use(Recovery()) r.Mount("/", WebRoutes()) r.Mount("/api/v1", apiv1.Routes()) @@ -124,6 +123,8 @@ func WebRoutes() *web.Route { Domain: setting.SessionConfig.Domain, })) + r.Use(Recovery()) + r.Use(public.Custom( &public.Options{ SkipLogging: setting.DisableRouterLog,