Skip to content

Commit b43adc3

Browse files
committed
Guard against blank auth value
This shouldn't be possible, but was previously handled by the library
1 parent 1036e04 commit b43adc3

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

‎lib/entry-points.js‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎src/api-client.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,8 @@ function createApiClientWithDetails(
138138
const requestOptions = makeProxyRequestOptions(proxy);
139139

140140
const opts: OctokitOptions = {
141-
auth: auth !== undefined ? `token ${auth}` : undefined,
141+
auth:
142+
auth !== undefined && auth.trim() !== "" ? `token ${auth}` : undefined,
142143
baseUrl: apiDetails.apiURL,
143144
userAgent: `CodeQL-Action/${getActionVersion()}`,
144145
log: {

0 commit comments

Comments
 (0)