File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -55,24 +55,24 @@ jobs:
55
55
const { owner, repo } = context.repo;
56
56
const { default_branch: branch } = context.payload.repository;
57
57
58
- const branch = github.rest.repos.getBranch({ owner, repo, branch });
58
+ const branchData = github.rest.repos.getBranch({ owner, repo, branch });
59
59
60
- const checkSuites = await github.rest.checks.listSuitesForRef({ owner, repo, ref });
60
+ const { data: { check_suites: checkSuites } } = await github.rest.checks.listSuitesForRef({ owner, repo, ref });
61
61
62
62
if (checkSuites.some(({ status }) => 'completed')) {
63
63
core.setFailed(`Some workflows for ${context.payload.inputs.tag} are still in-progress`);
64
64
}
65
65
66
66
const { data: { check_runs: checkRuns } } = await Promise.all(
67
- (await branch ).data.protection.required_status_checks.checks.map(({ context }) => (
67
+ (await branchData ).data.protection.required_status_checks.checks.map(({ context }) => (
68
68
github.rest.checks.listForRef({
69
69
owner,
70
70
repo,
71
71
ref,
72
- check_name: context
72
+ check_name: context,
73
73
})
74
- )
75
- )
74
+ ))
75
+ );
76
76
77
77
checkRuns.forEach(({ name, status, conclusion }) => {
78
78
if (status !== 'completed' || conclusion !== 'success') {
You can’t perform that action at this time.
0 commit comments