Socket
Socket
Sign inDemoInstall

event-stream

Package Overview
Dependencies
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

event-stream - npm Package Compare versions

Comparing version 3.0.7 to 3.0.8

49

index.js

@@ -14,3 +14,4 @@ //filter will reemit the data if cb(err,pass) pass is truthy

, pause = require('pause-stream')
, split = require('split')
, split = require('split')
, pipeline = require('stream-combiner')

@@ -24,3 +25,3 @@ es.Stream = Stream //re-export Stream from core

es.split = split
es.pipeline = es.connect = es.pipe = pipeline
// merge / concat

@@ -131,3 +132,4 @@ //

es.readable = function (func, continueOnError) {
es.readable =
function (func, continueOnError) {
var stream = new Stream()

@@ -185,3 +187,2 @@ , i = 0

//

@@ -212,43 +213,3 @@ // map sync

//
// combine multiple streams together so that they act as a single stream
//
es.pipeline =
es.pipe = es.connect = function () {
var streams = [].slice.call(arguments)
, first = streams[0]
, last = streams[streams.length - 1]
, thepipe = es.duplex(first, last)
if(streams.length == 1)
return streams[0]
else if (!streams.length)
throw new Error('connect called with empty args')
//pipe all the streams together
function recurse (streams) {
if(streams.length < 2)
return
streams[0].pipe(streams[1])
recurse(streams.slice(1))
}
recurse(streams)
function onerror () {
var args = [].slice.call(arguments)
args.unshift('error')
thepipe.emit.apply(thepipe, args)
}
//es.duplex already reemits the error from the first and last stream.
//add a listener for the inner streams in the pipeline.
for(var i = 1; i < streams.length - 1; i ++)
streams[i].on('error', onerror)
return thepipe
}
//

@@ -255,0 +216,0 @@ // child -- pipe through a child process

6

package.json
{
"name": "event-stream",
"version": "3.0.7",
"version": "3.0.8",
"description": "construct pipes of streams of events",

@@ -11,3 +11,2 @@ "homepage": "http://github.com/dominictarr/event-stream",

"dependencies": {
"optimist": "0.2",
"through": "1.1.0",

@@ -18,3 +17,4 @@ "duplexer": "~0.0.2",

"pause-stream": "0.0.4",
"split": "0.0.0"
"split": "0.0.0",
"stream-combiner": "0.0.0"
},

@@ -21,0 +21,0 @@ "devDependencies": {

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