ci: replaced forEach by a loop

This commit is contained in:
Sergiu Deitsch 2021-11-19 22:01:06 +01:00
parent 1da31df93c
commit 5a3bd74cfa

View File

@ -24,7 +24,7 @@ jobs:
run_id: ${{github.event.workflow_run.id}}, run_id: ${{github.event.workflow_run.id}},
}); });
var matchArtifacts = artifacts.data.artifacts; var matchArtifacts = artifacts.data.artifacts;
matchArtifacts.forEach(artifact => { for (artifact of matchArtifacts) {
var download = await github.actions.downloadArtifact({ var download = await github.actions.downloadArtifact({
owner: context.repo.owner, owner: context.repo.owner,
repo: context.repo.repo, repo: context.repo.repo,
@ -33,7 +33,7 @@ jobs:
}); });
var fs = require('fs'); var fs = require('fs');
fs.writeFileSync('${{github.workspace}}/' + artifact.name + '.zip', Buffer.from(download.data)); fs.writeFileSync('${{github.workspace}}/' + artifact.name + '.zip', Buffer.from(download.data));
}); }
- name: Unpack artifacts - name: Unpack artifacts
run: | run: |