Commit 4a1fa615 authored by eric sciple's avatar eric sciple
Browse files

.

parent 19fb09ae
Loading
Loading
Loading
Loading
+2
Changes for dist/index.js: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -8391,9 +8391,11 @@ function downloadRepository(accessToken, owner, repo, ref, commit, repositoryPat
                    ref: refHelper.getDownloadRef(ref, commit)
                };
                const response = yield octokit.repos.getArchiveLink(params);
                console.log('GOT THE RESPONSE');
                if (response.status != 302) {
                    throw new Error(`Unexpected response from GitHub API. Status: '${response.status}'`);
                }
                console.log('GETTING THE LOCATION');
                const archiveUrl = response.headers['Location']; // Do not print the archive URL because it has an embedded token
                assert.ok(archiveUrl, `Expected GitHub API response to contain 'Location' header`);
                // Download the archive
+2
Changes for src/github-api-helper.ts: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -51,11 +51,13 @@ export async function downloadRepository(
        ref: refHelper.getDownloadRef(ref, commit)
      }
      const response = await octokit.repos.getArchiveLink(params)
      console.log('GOT THE RESPONSE')
      if (response.status != 302) {
        throw new Error(
          `Unexpected response from GitHub API. Status: '${response.status}'`
        )
      }
      console.log('GETTING THE LOCATION')
      const archiveUrl = response.headers['Location'] // Do not print the archive URL because it has an embedded token
      assert.ok(
        archiveUrl,