diff --git a/routers/web/web.go b/routers/web/web.go index c37add30d53..8b260867aa8 100644 --- a/routers/web/web.go +++ b/routers/web/web.go @@ -1229,7 +1229,7 @@ func registerWebRoutes(m *web.Router) { m.Group("/{username}/{reponame}/{type:issues}", func() { // these handlers also check unit permissions internally m.Get("", repo.Issues) - m.Get("/{index}", repo.ViewIssue) // also do pull-request redirection (".../issues/{PR-number}" -> ".../pulls/{PR-number}") + m.Get("/{index}", repo.SetEditorconfigIfExists, repo.ViewIssue) // also do pull-request redirection (".../issues/{PR-number}" -> ".../pulls/{PR-number}") }, optSignIn, context.RepoAssignment, context.RequireUnitReader(unit.TypeIssues, unit.TypePullRequests, unit.TypeExternalTracker)) // end "/{username}/{reponame}": issue list, issue view (pull-request redirection), external tracker @@ -1530,7 +1530,7 @@ func registerWebRoutes(m *web.Router) { m.Group("/{username}/{reponame}", func() { m.Get("/{type:pulls}", repo.Issues) m.Group("/{type:pulls}/{index}", func() { - m.Get("", repo.SetWhitespaceBehavior, repo.GetPullDiffStats, repo.ViewIssue) + m.Get("", repo.SetEditorconfigIfExists, repo.SetWhitespaceBehavior, repo.GetPullDiffStats, repo.ViewIssue) m.Get(".diff", repo.DownloadPullDiff) m.Get(".patch", repo.DownloadPullPatch) m.Get("/merge_box", repo.ViewPullMergeBox)