mirror of
https://github.com/go-gitea/gitea.git
synced 2024-09-06 23:44:20 -04:00
This reverts commit 3c63c3ace4
.
This commit is contained in:
parent
3c63c3ace4
commit
0a80164bec
@ -862,7 +862,7 @@ func RegisterRoutes(m *macaron.Macaron) {
|
||||
m.Group("/topics", func() {
|
||||
m.Get("/search", repo.TopicSearch)
|
||||
})
|
||||
}, securityHeaders(), reqTokenBySetting(), context.APIContexter(), sudo())
|
||||
}, securityHeaders(), context.APIContexter(), sudo())
|
||||
}
|
||||
|
||||
func securityHeaders() macaron.Handler {
|
||||
@ -874,10 +874,3 @@ func securityHeaders() macaron.Handler {
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
func reqTokenBySetting() macaron.Handler {
|
||||
if setting.Service.RequireSignInView {
|
||||
return reqToken()
|
||||
}
|
||||
return func(ctx *macaron.Context) {}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user