Skip to content

Commit

Permalink
fix(agent): don't use polynomial regex
Browse files Browse the repository at this point in the history
  • Loading branch information
wraithgar committed Feb 8, 2022
1 parent ed7f983 commit 61856c6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/agent.js
Expand Up @@ -89,7 +89,7 @@ function checkNoProxy (uri, opts) {
const host = new url.URL(uri).hostname.split('.').reverse()
let noproxy = (opts.noProxy || getProcessEnv('no_proxy'))
if (typeof noproxy === 'string') {
noproxy = noproxy.split(/\s*,\s*/g)
noproxy = noproxy.split(',').map(n => n.trim())
}

return noproxy && noproxy.some(no => {
Expand Down

0 comments on commit 61856c6

Please sign in to comment.