@@ -749,9 +749,11 @@ func RegisterRoutes(m *macaron.Macaron) {
749
749
m .Post ("/reactions/:action" , bindIgnErr (auth.ReactionForm {}), repo .ChangeIssueReaction )
750
750
m .Post ("/lock" , reqRepoIssueWriter , bindIgnErr (auth.IssueLockForm {}), repo .LockIssue )
751
751
m .Post ("/unlock" , reqRepoIssueWriter , repo .UnlockIssue )
752
+ }, context .RepoMustNotBeArchived ())
753
+ m .Group ("/:index" , func () {
752
754
m .Get ("/attachments" , repo .GetIssueAttachments )
753
755
m .Get ("/attachments/:uuid" , repo .GetAttachment )
754
- }, context . RepoMustNotBeArchived () )
756
+ })
755
757
756
758
m .Post ("/labels" , reqRepoIssuesOrPullsWriter , repo .UpdateIssueLabel )
757
759
m .Post ("/milestone" , reqRepoIssuesOrPullsWriter , repo .UpdateIssueMilestone )
@@ -767,8 +769,10 @@ func RegisterRoutes(m *macaron.Macaron) {
767
769
m .Post ("" , repo .UpdateCommentContent )
768
770
m .Post ("/delete" , repo .DeleteComment )
769
771
m .Post ("/reactions/:action" , bindIgnErr (auth.ReactionForm {}), repo .ChangeCommentReaction )
770
- m .Get ("/attachments" , repo .GetCommentAttachments )
771
772
}, context .RepoMustNotBeArchived ())
773
+ m .Group ("/comments/:id" , func () {
774
+ m .Get ("/attachments" , repo .GetCommentAttachments )
775
+ })
772
776
m .Group ("/labels" , func () {
773
777
m .Post ("/new" , bindIgnErr (auth.CreateLabelForm {}), repo .NewLabel )
774
778
m .Post ("/edit" , bindIgnErr (auth.CreateLabelForm {}), repo .UpdateLabel )
0 commit comments