Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

get-url-proxy

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

get-url-proxy - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

proxy-list.js

2

package.json
{
"name": "get-url-proxy",
"version": "1.0.1",
"version": "1.0.2",
"description": "get-url-proxy will return the applicable proxy to use for a given URL based on NO_PROXY and PROT_PROXY environment variables",

@@ -5,0 +5,0 @@ "main": "index.js",

var normalizeProtocols = require('./normalize-protocols');
var proxies = require('./proxy-list');

@@ -7,11 +8,8 @@ module.exports = function getProxyForProtocol(protocol) {

for (var i=0; i<prots.length; i++) {
var prot = prots[i];
if (process.env[prot + '_PROXY']) {
return process.env[prot + '_PROXY'];
var proxy = proxies[prots[i]];
if (proxy) {
return proxy;
}
if (process.env[prot.toLowerCase() + '_proxy']) {
return process.env[prot.toLowerCase() + '_proxy'];
}
}
return null;
};

@@ -34,3 +34,3 @@ # node-get-url-proxy

* `HTTP` -> [`HTTP`. `HTTPS`]
* `HTTP` -> [`HTTP`, `HTTPS`]
* `HTTPS` -> [`HTTPS`, `HTTP`]

@@ -37,0 +37,0 @@ * `WS` -> [`WS`, `WSS`, `HTTPS`, `HTTP`]

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc