diff --git a/routers/web/repo/issue.go b/routers/web/repo/issue.go index f9ec2a3604..ece290bf30 100644 --- a/routers/web/repo/issue.go +++ b/routers/web/repo/issue.go @@ -3321,16 +3321,6 @@ func GetCommentAttachments(ctx *context.Context) { return } - if err := comment.LoadIssue(ctx); err != nil { - ctx.NotFoundOrServerError("LoadIssue", issues_model.IsErrIssueNotExist, err) - return - } - - if comment.Issue.RepoID != ctx.Repo.Repository.ID { - ctx.NotFound("CompareRepoID", issues_model.ErrCommentNotExist{}) - return - } - if !comment.Type.HasAttachmentSupport() { ctx.ServerError("GetCommentAttachments", fmt.Errorf("comment type %v does not support attachments", comment.Type)) return