summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorjaqra <48099350+jaqra@users.noreply.github.com>2019-10-25 10:19:04 +0300
committerzeripath <art27@cantab.net>2019-10-25 08:19:04 +0100
commitfc0580a4b743c967be9f12f9efcb8206d4824206 (patch)
tree1b669e1cca319735187793d79502903c3bb9eac6 /models
parenta520236cb5593d041cee3829c230b8e6791c2b26 (diff)
downloadgitea-fc0580a4b743c967be9f12f9efcb8206d4824206.tar.gz
gitea-fc0580a4b743c967be9f12f9efcb8206d4824206.zip
make call createMilestoneComment on newIssue func (#8678)
* make call createMilestoneComment on newIssue func * make OldMilestoneID 0 instead of -1
Diffstat (limited to 'models')
-rw-r--r--models/issue.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/models/issue.go b/models/issue.go
index f006917891..52af872ccc 100644
--- a/models/issue.go
+++ b/models/issue.go
@@ -970,6 +970,10 @@ func newIssue(e *xorm.Session, doer *User, opts NewIssueOptions) (err error) {
if _, err = e.Exec("UPDATE `milestone` SET num_issues=num_issues+1 WHERE id=?", opts.Issue.MilestoneID); err != nil {
return err
}
+
+ if _, err = createMilestoneComment(e, doer, opts.Repo, opts.Issue, 0, opts.Issue.MilestoneID); err != nil {
+ return err
+ }
}
// Insert the assignees