Skip to content

Commit 9bb6ecc

Browse files
authored
Update notifier.go
1 parent 5e3e00f commit 9bb6ecc

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

services/actions/notifier.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,15 @@ func (n *actionsNotifier) NewIssue(ctx context.Context, issue *issues_model.Issu
5858
// IssueChangeContent notifies change content of issue
5959
func (n *actionsNotifier) IssueChangeContent(ctx context.Context, doer *user_model.User, issue *issues_model.Issue, oldContent string) {
6060
ctx = withMethod(ctx, "IssueChangeContent")
61-
n.notifyIssueChangeWithTitleOrContent(ctx, doer, issue, api.HookIssueEdited)
61+
n.notifyIssueChangeWithTitleOrContent(ctx, doer, issue)
6262
}
6363

6464
func (n *actionsNotifier) IssueChangeTitle(ctx context.Context, doer *user_model.User, issue *issues_model.Issue, oldTitle string) {
6565
ctx = withMethod(ctx, "IssueChangeTitle")
66-
n.notifyIssueChangeWithTitleOrContent(ctx, doer, issue, api.HookIssueEdited)
66+
n.notifyIssueChangeWithTitleOrContent(ctx, doer, issue)
6767
}
6868

69-
func (n *actionsNotifier) notifyIssueChangeWithTitleOrContent(ctx context.Context, doer *user_model.User, issue *issues_model.Issue, action api.HookIssueAction) {
69+
func (n *actionsNotifier) notifyIssueChangeWithTitleOrContent(ctx context.Context, doer *user_model.User, issue *issues_model.Issue) {
7070
var err error
7171
if err = issue.LoadRepo(ctx); err != nil {
7272
log.Error("LoadRepo: %v", err)
@@ -82,7 +82,7 @@ func (n *actionsNotifier) notifyIssueChangeWithTitleOrContent(ctx context.Contex
8282
newNotifyInputFromIssue(issue, webhook_module.HookEventPullRequest).
8383
WithDoer(doer).
8484
WithPayload(&api.PullRequestPayload{
85-
Action: action,
85+
Action: api.HookIssueEdited,
8686
Index: issue.Index,
8787
PullRequest: convert.ToAPIPullRequest(ctx, issue.PullRequest, nil),
8888
Repository: convert.ToRepo(ctx, issue.Repo, access_model.Permission{AccessMode: perm_model.AccessModeNone}),

0 commit comments

Comments
 (0)