Skip to content

Commit a224b2a

Browse files
committed
Add extra check to coverage monitor
Only adds comment if GitHub event is a pull request, previously push events would run this still.
1 parent 89df447 commit a224b2a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

.github/workflows/unit-tests.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ jobs:
9696
path: ${{ github.workspace }}/app/coverage
9797
retention-days: 1
9898
- name: Monitor Coverage
99-
if: "matrix.node-version == '22.x' && ! github.event.pull_request.head.repo.fork"
99+
if: "matrix.node-version == '22.x' && github.event_name == 'pull_request' && ! github.event.pull_request.head.repo.fork"
100100
uses: slavcodev/coverage-monitor-action@398c4cbbb710e549a8407fdef96ae8b9454d0463 # 1.10.0
101101
with:
102102
comment_mode: update
@@ -162,7 +162,7 @@ jobs:
162162
path: ${{ github.workspace }}/frontend/coverage
163163
retention-days: 1
164164
- name: Monitor Coverage
165-
if: "matrix.node-version == '22.x' && ! github.event.pull_request.head.repo.fork"
165+
if: "matrix.node-version == '22.x' && github.event_name == 'pull_request' && ! github.event.pull_request.head.repo.fork"
166166
uses: slavcodev/coverage-monitor-action@398c4cbbb710e549a8407fdef96ae8b9454d0463 # 1.10.0
167167
with:
168168
comment_mode: update

0 commit comments

Comments
 (0)