@superhero/http-request 4.0.6 → 4.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +1 -1
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -346,7 +346,7 @@ export default class Request
346
346
  #resolveHttp1Client(options, method, headers, url, accept, reject)
347
347
  {
348
348
  const
349
- request = url.protocol === 'https:' ? https.request : http.request,
349
+ request = url.startsWith('https:') ? https.request : http.request,
350
350
  config = Object.assign({}, options, { headers }),
351
351
  upstream = request(url, config)
352
352
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@superhero/http-request",
3
- "version": "4.0.6",
3
+ "version": "4.0.7",
4
4
  "description": "HTTP request component supporting HTTP 1.1 and HTTP 2.0",
5
5
  "keywords": [
6
6
  "http request",