Skip to content

Commit

Permalink
Do not pass undefined authorization header
Browse files Browse the repository at this point in the history
  • Loading branch information
henrymercer committed Nov 11, 2024
1 parent acb9cb1 commit ebbe050
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/tools-download.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/tools-download.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/tools-download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,8 @@ async function downloadAndExtractZstdWithStreaming(
logger: Logger,
): Promise<string> {
headers = Object.assign(
{ "User-Agent": "CodeQL Action", authorization },
{ "User-Agent": "CodeQL Action" },
authorization ? { authorization } : {},
headers,
);
const response = await new Promise<IncomingMessage>((resolve) =>
Expand Down

0 comments on commit ebbe050

Please sign in to comment.