Skip to content

Commit

Permalink
master: 2021-03-02 19:28:49
Browse files Browse the repository at this point in the history
  • Loading branch information
LamaAni committed Feb 4, 2021
1 parent c9a3794 commit 2bd814a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion parse_commit_args.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,12 @@ async function get_commits(context = null) {
/**
* @type {[Object]}
*/
const all_commits = await get_json_request(commits_url, null, {
let all_commits = await get_json_request(commits_url, null, {
'User-Agent': 'parse-commit-args-action',
})

all_commits = Array.isArray(all_commits) ? all_commits : [all_commits]

return all_commits.map((c) => c.commit)
}

Expand Down
1 change: 1 addition & 0 deletions parse_commit_args.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ async function test_context(context) {
}

async function main() {
await test_context(require('./.local/example_release_context.json'))
await test_context(require('./.local/example_push_context.json'))
await test_context(require('./.local/example_pr_context.json'))
}
Expand Down

0 comments on commit 2bd814a

Please sign in to comment.