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

fermata

Package Overview
Dependencies
Maintainers
1
Versions
47
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fermata - npm Package Compare versions

Comparing version 0.11.0-beta3 to 0.11.0-beta4

20

fermata.js

@@ -129,5 +129,3 @@ /*

url_parts = require('url').parse(url),
headers = {},
data = null, stream = null,
textResponse = true, streamResponse = false;
headers = {};

@@ -334,2 +332,16 @@ request.options.responseType || (request.options.responseType = 'text'); // 'text', 'stream', 'buffer'

fermata.registerPlugin('timeout', function (transport, duration) {
return function (request, callback) {
var _req, watchdog = setTimeout(function () {
watchdog = null; // signals logic below
_req.abort();
}, duration || 60e3);
return _req = transport(request, function (err, response) {
if (!watchdog) err = Error("Request timed out.");
else clearTimeout(watchdog);
callback(err, response);
});
};
});
fermata.registerPlugin('statusCheck', function (transport) {

@@ -454,3 +466,3 @@ return function (request, callback) {

this.base = baseURL;
return transport.using('statusCheck').using('autoConvert', "application/json");
return transport.using('timeout').using('statusCheck').using('autoConvert', "application/json");
});

@@ -457,0 +469,0 @@

2

package.json
{
"name": "fermata",
"version": "0.11.0-beta3",
"version": "0.11.0-beta4",
"homepage": "https://github.com/natevw/fermata",

@@ -5,0 +5,0 @@ "repository":{"type":"git", "url":"https://github.com/natevw/fermata.git"},

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