We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8a0817a commit 53e8bacCopy full SHA for 53e8bac
.github/workflows/bundle-compare.yml
@@ -60,21 +60,21 @@ jobs:
60
owner: context.repo.owner,
61
repo: context.repo.repo,
62
workflow_id: 64771488 || context.payload.workflow_run.workflow_id,
63
- branch: 'main',
+ branch: 'bundle-stats' || 'main',
64
status: 'completed',
65
per_page: 1,
66
});
67
68
+ if (runs.length < 1) {
69
+ throw new Error('No runs found!');
70
+ }
71
+
72
const artifacts = await github.rest.actions.listWorkflowRunArtifacts({
73
74
75
run_id: runs.data.workflow_runs[0].id,
76
77
- if (!runs) {
- throw new Error('No artifact found!');
- }
-
78
const artifact = artifacts.data.artifacts.find(a => a.name === 'webpack-stats');
79
80
if (!artifact) {
0 commit comments