Socket
Socket
Sign inDemoInstall

download

Package Overview
Dependencies
Maintainers
3
Versions
70
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

download - npm Package Compare versions

Comparing version 4.2.0 to 4.2.1

16

index.js

@@ -15,3 +15,3 @@ 'use strict';

var streamCombiner = require('stream-combiner2');
var through = require('through2');
var PassThrough = require('readable-stream/passthrough');
var Vinyl = require('vinyl');

@@ -124,3 +124,3 @@ var vinylFs = require('vinyl-fs');

var agent = caw(this.opts.proxy, {protocol: protocol});
var stream = got(get.url, objectAssign(this.opts, {agent: agent}));
var stream = got.stream(get.url, objectAssign(this.opts, {agent: agent}));

@@ -133,4 +133,14 @@ stream.on('response', function (res) {

var hasHttpError = false;
readAllStream(stream, null, function (err, data) {
if (hasHttpError) {
return;
}
if (err) {
if (err instanceof got.HTTPError) {
hasHttpError = true;
}
done(err);

@@ -183,3 +193,3 @@ return;

Download.prototype.createStream = function (file, dest) {
var stream = through.obj();
var stream = new PassThrough({objectMode: true});
var streams = [stream];

@@ -186,0 +196,0 @@

19

package.json
{
"name": "download",
"version": "4.2.0",
"version": "4.2.1",
"description": "Download and extract files",

@@ -16,3 +16,3 @@ "license": "MIT",

"scripts": {
"test": "node test/test.js"
"test": "xo && ava"
},

@@ -34,11 +34,11 @@ "files": [

"filenamify": "^1.0.1",
"got": "^2.3.2",
"got": "^4.2.0",
"gulp-decompress": "^1.0.2",
"gulp-rename": "^1.2.0",
"is-url": "^1.2.0",
"object-assign": "^2.0.0",
"object-assign": "^4.0.1",
"read-all-stream": "^3.0.0",
"readable-stream": "^2.0.2",
"stream-combiner2": "^1.0.2",
"through2": "^2.0.0",
"vinyl": "^0.4.3",
"vinyl": "^0.5.3",
"vinyl-fs": "^1.0.0",

@@ -48,6 +48,7 @@ "ware": "^1.2.0"

"devDependencies": {
"ava": "^0.0.4",
"nock": "^1.2.1",
"rimraf": "^2.2.8"
"ava": "^0.2.0",
"nock": "^2.12.0",
"rimraf": "^2.2.8",
"xo": "*"
}
}
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