- Also create tests for this middleware
Co-authored-by: Kyle Brandt <kyle@grafana.com>
(cherry picked from commit 06ed5efdf0)
Co-authored-by: ying-jeanne <74549700+ying-jeanne@users.noreply.github.com>
This commit is contained in:
co-authored by
ying-jeanne
parent
e7f52218d1
commit
b0646b1be3
@@ -441,7 +441,7 @@ func (hs *HTTPServer) addMiddlewaresAndStaticRoutes() {
|
||||
}
|
||||
|
||||
m.Use(middleware.Recovery(hs.Cfg))
|
||||
m.UseMiddleware(middleware.CSRF(hs.Cfg.LoginCookieName))
|
||||
m.UseMiddleware(middleware.CSRF(hs.Cfg.LoginCookieName, hs.log))
|
||||
|
||||
hs.mapStatic(m, hs.Cfg.StaticRootPath, "build", "public/build")
|
||||
hs.mapStatic(m, hs.Cfg.StaticRootPath, "", "public", "/public/views/swagger.html")
|
||||
|
||||
Reference in New Issue
Block a user