Skip to content

Commit

Permalink
fix(deps): update dependency https-proxy-agent to v7 (#636)
Browse files Browse the repository at this point in the history
  • Loading branch information
renovate[bot] committed May 28, 2023
1 parent 3dc59ec commit 0f12010
Show file tree
Hide file tree
Showing 3 changed files with 119 additions and 115 deletions.
10 changes: 6 additions & 4 deletions lib/get-client.js
@@ -1,6 +1,6 @@
const urljoin = require('url-join');
const HttpProxyAgent = require('http-proxy-agent');
const HttpsProxyAgent = require('https-proxy-agent');
const {HttpProxyAgent} = require('http-proxy-agent');
const {HttpsProxyAgent} = require('https-proxy-agent');

const SemanticReleaseOctokit = require('./semantic-release-octokit');

Expand All @@ -12,8 +12,10 @@ module.exports = ({githubToken, githubUrl, githubApiPathPrefix, proxy}) => {
request: {
agent: proxy
? baseUrl && new URL(baseUrl).protocol.replace(':', '') === 'http'
? new HttpProxyAgent(proxy)
: new HttpsProxyAgent(proxy)
? // Some `proxy.headers` need to be passed as second arguments since version 6 or 7
// For simplicity, we just pass the same proxy object twice. It works 🤷🏻
new HttpProxyAgent(proxy, proxy)
: new HttpsProxyAgent(proxy, proxy)
: undefined,
},
});
Expand Down
220 changes: 111 additions & 109 deletions package-lock.json

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

0 comments on commit 0f12010

Please sign in to comment.