diff --git a/.github/workflows/update-pr-labels.yml b/.github/workflows/update-pr-labels.yml index 029c3393f172..e5e00c1f8a6a 100644 --- a/.github/workflows/update-pr-labels.yml +++ b/.github/workflows/update-pr-labels.yml @@ -5,7 +5,8 @@ permissions: on: issue_comment: types: [created] - pull_request_review_thread: + pull_request_review_comment: + types: [created] jobs: issue_comment: @@ -24,13 +25,13 @@ jobs: labels: ["user responded"] }) - pull_request_review_thread: + pull_request_review_comment: if: github.event.pull_request runs-on: ubuntu-latest steps: - name: update label when user responds uses: actions/github-script@v6 - if: github.event.pull_request.labels && !contains(github.event.pull_request.labels.*.name, 'user responded') + if: github.event.comment.user.login == github.event.pull_request.user.login && github.event.pull_request.labels && !contains(github.event.pull_request.labels.*.name, 'user responded') with: script: | github.rest.issues.addLabels({