summaryrefslogtreecommitdiffstats
path: root/routers/api/v1
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2017-02-01 10:36:08 +0800
committerGitHub <noreply@github.com>2017-02-01 10:36:08 +0800
commit081485ecfddc88a05fdea0b0230672271658c086 (patch)
treebbaaa55ede02f311056f5df6c8b56301be09982d /routers/api/v1
parent10644d6dd7574b031118bf01b2bd737017230ffd (diff)
downloadgitea-081485ecfddc88a05fdea0b0230672271658c086.tar.gz
gitea-081485ecfddc88a05fdea0b0230672271658c086.zip
add milestone changed traker on issue view (#804)
Diffstat (limited to 'routers/api/v1')
-rw-r--r--routers/api/v1/repo/issue.go2
-rw-r--r--routers/api/v1/repo/pull.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/routers/api/v1/repo/issue.go b/routers/api/v1/repo/issue.go
index ac0289c412..c65f4b7063 100644
--- a/routers/api/v1/repo/issue.go
+++ b/routers/api/v1/repo/issue.go
@@ -168,7 +168,7 @@ func EditIssue(ctx *context.APIContext, form api.EditIssueOption) {
issue.MilestoneID != *form.Milestone {
oldMilestoneID := issue.MilestoneID
issue.MilestoneID = *form.Milestone
- if err = models.ChangeMilestoneAssign(issue, oldMilestoneID); err != nil {
+ if err = models.ChangeMilestoneAssign(issue, ctx.User, oldMilestoneID); err != nil {
ctx.Error(500, "ChangeMilestoneAssign", err)
return
}
diff --git a/routers/api/v1/repo/pull.go b/routers/api/v1/repo/pull.go
index 4c10024bfb..9a38d37528 100644
--- a/routers/api/v1/repo/pull.go
+++ b/routers/api/v1/repo/pull.go
@@ -241,7 +241,7 @@ func EditPullRequest(ctx *context.APIContext, form api.EditPullRequestOption) {
issue.MilestoneID != form.Milestone {
oldMilestoneID := issue.MilestoneID
issue.MilestoneID = form.Milestone
- if err = models.ChangeMilestoneAssign(issue, oldMilestoneID); err != nil {
+ if err = models.ChangeMilestoneAssign(issue, ctx.User, oldMilestoneID); err != nil {
ctx.Error(500, "ChangeMilestoneAssign", err)
return
}