summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--routers/repo/issue.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/repo/issue.go b/routers/repo/issue.go
index c9d3112eaa..6becb2dff7 100644
--- a/routers/repo/issue.go
+++ b/routers/repo/issue.go
@@ -1158,7 +1158,7 @@ func IssueDeleteAttachment(ctx *middleware.Context, params martini.Params) {
return
}
- if comment.PosterId != ctx.User.Id {
+ if comment.PosterId != ctx.User.Id && !ctx.User.IsAdmin {
ctx.JSON(400, map[string]interface{}{
"ok": false,
"error": "no permissions",