Update routers/web/web.go

Co-authored-by: metiftikci <metiftikci@hotmail.com>
This commit is contained in:
Lunny Xiao 2025-02-18 16:26:26 -08:00 committed by GitHub
parent 5bf1438e42
commit b89a96105c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1268,7 +1268,7 @@ func registerRoutes(m *web.Router) {
m.Delete("/unpin/{index}", reqRepoAdmin, repo.IssueUnpin)
m.Post("/move_pin", reqRepoAdmin, repo.IssuePinMove)
}
// FIXME: many "pulls" requests are sent to "issues" endpoints correctly, so the issue endpoints have to tolerate pull request permissions at the moment
// FIXME: many "pulls" requests are sent to "issues" endpoints incorrectly, so the issue endpoints have to tolerate pull request permissions at the moment
m.Group("/{type:issues}", addIssuesPullsUpdateRoutes, context.RequireUnitReader(unit.TypeIssues, unit.TypePullRequests), context.RepoMustNotBeArchived())
m.Group("/{type:pulls}", addIssuesPullsUpdateRoutes, reqUnitPullsReader, context.RepoMustNotBeArchived())