Skip to content

Commit 679b721

Browse files
authored
Try to fix commenter (#44549)
1 parent 229fbf7 commit 679b721

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

.github/workflows/live-protection.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1+
name: Base branch checker
12
on: [pull_request]
23

34
permissions:
45
contents: read
56

67
jobs:
78
live_protection_job:
8-
name: Prevent unintended merge to live
9+
name: Create comment
910
runs-on: ubuntu-latest
1011
steps:
1112
- name: Harden Runner
@@ -19,10 +20,10 @@ jobs:
1920
with:
2021
script: |
2122
if (process.env.SHOULD_COMMENT == 'true') {
22-
github.issues.createComment({
23+
github.rest.issues.createComment({
2324
issue_number: context.issue.number,
2425
owner: context.repo.owner,
2526
repo: context.repo.repo,
26-
body: 'It looks like this pull request was opened on the `live` branch by mistake. In general, PRs should target the `main` branch.'
27+
body: 'It looks like this pull request was opened on the live branch by mistake. In general, PRs should target main.'
2728
})
2829
}

0 commit comments

Comments
 (0)