Comparing version 0.9.3 to 0.9.4
@@ -5,2 +5,3 @@ var Stream = require('stream'); | ||
var Buffer = require('buffer').Buffer; | ||
var strFunction = 'function'; | ||
@@ -60,3 +61,3 @@ // Backwards compatibility for node versions < 8 | ||
p.write(packet,function() { | ||
if (self.buffer.length === (eof.length || 0)) self.cb(); | ||
if (self.buffer.length === (eof.length || 0) && typeof self.cb === strFunction) self.cb(); | ||
}); | ||
@@ -63,0 +64,0 @@ } |
{ | ||
"name": "unzipper", | ||
"version": "0.9.3", | ||
"version": "0.9.4", | ||
"description": "Unzip cross-platform streaming API ", | ||
@@ -5,0 +5,0 @@ "author": "Evan Oxfeld <eoxfeld@gmail.com>", |
@@ -37,6 +37,6 @@ # unzipper [![Build Status](https://api.travis-ci.org/ZJONSSON/node-unzipper.png?branch=master)](https://travis-ci.org/ZJONSSON/node-unzipper?branch=master) | ||
__Important__: If you do not intend to consume an entry stream's raw data, call autodrain() to dispose of the entry's | ||
contents. Otherwise you the stream will halt. `.autodrain()` returns an empty stream that provides `error` and `finish` events. | ||
contents. Otherwise the stream will halt. `.autodrain()` returns an empty stream that provides `error` and `finish` events. | ||
Additionally you can call `.autodrain().promise()` to get the promisified version of success or failure of the autodrain. | ||
```js | ||
``` | ||
// If you want to handle autodrain errors you can either: | ||
@@ -43,0 +43,0 @@ entry.autodrain().catch(e => handleError); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
38396
789