stream-read
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -72,3 +72,12 @@ var dz = require('dezalgo'); | ||
function check() { | ||
var errored = false; | ||
var _onerror; | ||
stream.on('error', _onerror = function(err){ | ||
errored = true; | ||
stream.removeListener('error', _onerror); | ||
cb(err); | ||
}); | ||
var buf = stream.read(); | ||
if (errored) return; | ||
if (buf) cb(null, buf); | ||
@@ -75,0 +84,0 @@ else listen(); |
{ | ||
"name": "stream-read", | ||
"description": "Read from a stream, callback style", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"repository": "micnews/stream-read", | ||
"license": "MIT", | ||
"devDependencies": { | ||
"tape": "^3.0.0" | ||
"tape": "^3.0.0", | ||
"through": "~2.3.4" | ||
}, | ||
"dependencies": { | ||
"dezalgo": "^1.0.1" | ||
}, | ||
"scripts": { | ||
"test": "make test" | ||
} | ||
} |
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
5635
6
212
2
3440