unprint 0.11.9 → 0.11.10

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/package.json +1 -1
  2. package/src/app.js +2 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "unprint",
3
- "version": "0.11.9",
3
+ "version": "0.11.10",
4
4
  "description": "Simplify common web scraping tasks while staying in control of the data.",
5
5
  "main": "src/app.js",
6
6
  "scripts": {
package/src/app.js CHANGED
@@ -858,8 +858,8 @@ async function request(url, body, customOptions = {}, method = 'GET') {
858
858
  ...options,
859
859
  timeout: options.timeout,
860
860
  signal: options.abortSignal,
861
- httpAgent: new http.Agent({ ...options.agent }),
862
- httpsAgent: new https.Agent({ ...options.agent }),
861
+ httpAgent: options.httpAgent || new http.Agent({ ...options.agent }),
862
+ httpsAgent: options.httpsAgent || new https.Agent({ ...options.agent }),
863
863
  });
864
864
 
865
865
  if (!(res.status >= 200 && res.status < 300)) {