Skip to content

Commit

Permalink
https-proxy: work when they're not on a proxy
Browse files Browse the repository at this point in the history
  • Loading branch information
flotwig committed Feb 26, 2019
1 parent 2125e66 commit 4ffc140
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/https-proxy/lib/server.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class Server
.pipe(res)

_needsUpstreamProxy: (hostname, port) ->
hostname isnt "localhost" or getProxyFromURI("https://#{hostname}:#{port}")
process.env.HTTP_PROXY and (hostname isnt "localhost" or getProxyFromURI("https://#{hostname}:#{port}"))

_makeDirectConnection: (req, socket, head) ->
{ port, hostname } = url.parse("http://#{req.url}")
Expand Down

0 comments on commit 4ffc140

Please sign in to comment.