summaryrefslogtreecommitdiffstats
path: root/services/comments
diff options
context:
space:
mode:
authorJohn Olheiser <42128690+jolheiser@users.noreply.github.com>2019-10-18 17:42:04 -0500
committerzeripath <art27@cantab.net>2019-10-18 23:42:04 +0100
commit0a004a69cdcad2fa13d3d314cb984718c88a2940 (patch)
tree018ee4d70bba1b9b1f5de965cb35908380614687 /services/comments
parent05e437f8fd29d078af4148f3b2debcb789d8bfac (diff)
downloadgitea-0a004a69cdcad2fa13d3d314cb984718c88a2940.tar.gz
gitea-0a004a69cdcad2fa13d3d314cb984718c88a2940.zip
Improve webhooks (#8583)
* Improve webhooks Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update MSTeams and ReviewPayload comment Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add repo.FullName to comments Signed-off-by: jolheiser <john.olheiser@gmail.com>
Diffstat (limited to 'services/comments')
-rw-r--r--services/comments/comments.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/services/comments/comments.go b/services/comments/comments.go
index e8448e9065..010c0aaac7 100644
--- a/services/comments/comments.go
+++ b/services/comments/comments.go
@@ -38,6 +38,7 @@ func CreateIssueComment(doer *models.User, repo *models.Repository, issue *model
Comment: comment.APIFormat(),
Repository: repo.APIFormat(mode),
Sender: doer.APIFormat(),
+ IsPull: issue.IsPull,
}); err != nil {
log.Error("PrepareWebhooks [comment_id: %d]: %v", comment.ID, err)
} else {
@@ -128,6 +129,7 @@ func UpdateComment(c *models.Comment, doer *models.User, oldContent string) erro
},
Repository: c.Issue.Repo.APIFormat(mode),
Sender: doer.APIFormat(),
+ IsPull: c.Issue.IsPull,
}); err != nil {
log.Error("PrepareWebhooks [comment_id: %d]: %v", c.ID, err)
} else {
@@ -162,6 +164,7 @@ func DeleteComment(comment *models.Comment, doer *models.User) error {
Comment: comment.APIFormat(),
Repository: comment.Issue.Repo.APIFormat(mode),
Sender: doer.APIFormat(),
+ IsPull: comment.Issue.IsPull,
}); err != nil {
log.Error("PrepareWebhooks [comment_id: %d]: %v", comment.ID, err)
} else {