From 2f105f397965637c46ca6c0092a7c5fe38440dab Mon Sep 17 00:00:00 2001 From: Unknwon Date: Thu, 4 Aug 2016 16:32:02 -0700 Subject: #2162 completely disable builtin issue tracker when enable external tracker --- cmd/web.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'cmd/web.go') diff --git a/cmd/web.go b/cmd/web.go index dfd02013..39e297ee 100644 --- a/cmd/web.go +++ b/cmd/web.go @@ -449,7 +449,7 @@ func runWeb(ctx *cli.Context) error { m.Get("/:username/:reponame/action/:action", reqSignIn, context.RepoAssignment(), repo.Action) m.Group("/:username/:reponame", func() { m.Group("/issues", func() { - m.Combo("/new", repo.MustEnableIssues).Get(context.RepoRef(), repo.NewIssue). + m.Combo("/new").Get(context.RepoRef(), repo.NewIssue). Post(bindIgnErr(auth.CreateIssueForm{}), repo.NewIssuePost) m.Combo("/:index/comments").Post(bindIgnErr(auth.CreateCommentForm{}), repo.NewComment) @@ -463,7 +463,7 @@ func runWeb(ctx *cli.Context) error { m.Post("/title", repo.UpdateIssueTitle) m.Post("/content", repo.UpdateIssueContent) }) - }) + }, repo.MustEnableIssues) m.Group("/comments/:id", func() { m.Post("", repo.UpdateCommentContent) m.Post("/delete", repo.DeleteComment) @@ -472,7 +472,7 @@ func runWeb(ctx *cli.Context) error { m.Post("/new", bindIgnErr(auth.CreateLabelForm{}), repo.NewLabel) m.Post("/edit", bindIgnErr(auth.CreateLabelForm{}), repo.UpdateLabel) m.Post("/delete", repo.DeleteLabel) - }, reqRepoWriter, context.RepoRef()) + }, repo.MustEnableIssues, reqRepoWriter, context.RepoRef()) m.Group("/milestones", func() { m.Combo("/new").Get(repo.NewMilestone). Post(bindIgnErr(auth.CreateMilestoneForm{}), repo.NewMilestonePost) @@ -480,7 +480,7 @@ func runWeb(ctx *cli.Context) error { m.Post("/:id/edit", bindIgnErr(auth.CreateMilestoneForm{}), repo.EditMilestonePost) m.Get("/:id/:action", repo.ChangeMilestonStatus) m.Post("/delete", repo.DeleteMilestone) - }, reqRepoWriter, context.RepoRef()) + }, repo.MustEnableIssues, reqRepoWriter, context.RepoRef()) m.Group("/releases", func() { m.Get("/new", repo.NewRelease) -- cgit v1.2.3