Remove an unneeded check.

This commit is contained in:
Chris Gavin 2020-07-27 10:32:23 +01:00
parent 813cb0479f
commit 337dbe5618
No known key found for this signature in database
GPG key ID: 07F950B80C27E4DA
294 changed files with 3 additions and 133856 deletions

4
lib/codeql.js generated
View file

@ -15,7 +15,6 @@ const exec = __importStar(require("@actions/exec"));
const http = __importStar(require("@actions/http-client"));
const io = __importStar(require("@actions/io"));
const toolcache = __importStar(require("@actions/tool-cache"));
const rest_1 = require("@octokit/rest");
const fs = __importStar(require("fs"));
const path = __importStar(require("path"));
const semver = __importStar(require("semver"));
@ -72,9 +71,8 @@ async function getCodeQLBundleDownloadURL() {
return `https://github.com/${CODEQL_DEFAULT_ACTION_REPOSITORY}/releases/download/${CODEQL_DEFAULT_BUNDLE_VERSION}/${CODEQL_DEFAULT_BUNDLE_NAME}`;
}
let [repositoryOwner, repositoryName] = repository.split("/");
let client = apiURL === INSTANCE_API_URL ? api.getApiClient() : new rest_1.Octokit();
try {
const release = await client.repos.getReleaseByTag({
const release = await api.getApiClient().repos.getReleaseByTag({
owner: repositoryOwner,
repo: repositoryName,
tag: CODEQL_DEFAULT_BUNDLE_VERSION