We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 96f9c11 commit feb38daCopy full SHA for feb38da
routers/web/web.go
@@ -356,7 +356,12 @@ func registerRoutes(m *web.Route) {
356
m.Get("/users", explore.Users)
357
m.Get("/users/sitemap-{idx}.xml", sitemapEnabled, explore.Users)
358
m.Get("/organizations", explore.Organizations)
359
- m.Get("/code", reqUnitAccess(unit.TypeCode, perm.AccessModeRead), explore.Code)
+ m.Get("/code", func(ctx *context.Context) {
360
+ if unit.TypeCode.UnitGlobalDisabled() {
361
+ ctx.NotFound(unit.TypeCode.String(), nil)
362
+ return
363
+ }
364
+ }, explore.Code)
365
m.Get("/topics/search", explore.TopicSearch)
366
}, ignExploreSignIn)
367
m.Group("/issues", func() {
0 commit comments