diff --git a/models/actions/run.go b/models/actions/run.go index 7d5b7a5d50b..5f0f1907424 100644 --- a/models/actions/run.go +++ b/models/actions/run.go @@ -127,7 +127,7 @@ func (run *ActionRun) GetPushEventPayload() (*api.PushPayload, error) { } func (run *ActionRun) GetPullRequestEventPayload() (*api.PullRequestPayload, error) { - if run.Event == webhook_module.HookEventPullRequest { + if run.Event == webhook_module.HookEventPullRequest || run.Event == webhook_module.HookEventPullRequestSync { var payload api.PullRequestPayload if err := json.Unmarshal([]byte(run.EventPayload), &payload); err != nil { return nil, err diff --git a/services/actions/commit_status.go b/services/actions/commit_status.go index 84de106eeca..6604a149a5c 100644 --- a/services/actions/commit_status.go +++ b/services/actions/commit_status.go @@ -45,7 +45,7 @@ func CreateCommitStatus(ctx context.Context, job *actions_model.ActionRunJob) er sha = payload.HeadCommit.ID creatorID = payload.Pusher.ID - case webhook_module.HookEventPullRequest: + case webhook_module.HookEventPullRequest, webhook_module.HookEventPullRequestSync: payload, err := run.GetPullRequestEventPayload() if err != nil { return fmt.Errorf("GetPullRequestEventPayload: %w", err)