Skip to content

Commit

Permalink
feat: remove branch filter in runs search when event is of type relea…
Browse files Browse the repository at this point in the history
…se (#44)

* fix: remove branch filter in runs search when event is of type release

* Update find-successful-workflow.js

Co-authored-by: Miroslav Jonaš <[email protected]>
  • Loading branch information
ThomasAribart and meeroslav authored Jun 21, 2022
1 parent edec1c9 commit 8e1d815
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion find-successful-workflow.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,8 @@ async function findSuccessfulCommit(workflow_id, run_id, owner, repo, branch, la
const shas = await octokit.request(`GET /repos/${owner}/${repo}/actions/workflows/${workflow_id}/runs`, {
owner,
repo,
branch,
// on release workflow runs do not have branch property
branch: lastSuccessfulEvent === 'release' ? undefined : branch,
workflow_id,
event: lastSuccessfulEvent,
status: 'success'
Expand Down

0 comments on commit 8e1d815

Please sign in to comment.