Comparing version 2.0.0 to 2.1.0
var es = require('event-stream') | ||
function MuxDemux (opts) { | ||
if('function' === typeof opts) | ||
opts = {wrapper: opts} | ||
@@ -86,3 +88,6 @@ function createID() { | ||
var outer = es.connect(es.split(), es.parse(), md, es.stringify()) | ||
var outer = ( | ||
opts && opts.wrapper ? opts.wrapper(md) : | ||
es.pipeline(es.split(), es.parse(), md, es.stringify()) | ||
) | ||
@@ -89,0 +94,0 @@ if(md !== outer) |
{ | ||
"name": "mux-demux", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"description": "", | ||
@@ -11,3 +11,3 @@ "homepage": "http://github.com/dominictarr/mux-demux", | ||
"dependencies": { | ||
"event-stream": "~2.1.8" | ||
"event-stream": "~2.2" | ||
}, | ||
@@ -14,0 +14,0 @@ "scripts": { |
var es = require('event-stream') | ||
var a = require('assertions') | ||
module.exports = | ||
module.exports = | ||
function consistent(test) { | ||
@@ -39,1 +39,2 @@ test = test || a.deepEqual | ||
} | ||
@@ -12,2 +12,4 @@ /* | ||
module.exports = function (wrapper) { | ||
function randomNumberStream (max, count) { | ||
@@ -207,1 +209,6 @@ count = count || 20 | ||
})(); | ||
} | ||
if(!module.parent) | ||
module.exports() |
@@ -5,5 +5,7 @@ var a = require('assertions') | ||
var A = new MuxDemux() | ||
var B = new MuxDemux() | ||
module.exports = function (wrapper) { | ||
var A = new MuxDemux(wrapper) | ||
var B = new MuxDemux(wrapper) | ||
var connected, closed, ended, _hi | ||
@@ -48,1 +50,6 @@ | ||
a.ok(!ended) | ||
} | ||
if(!module.parent) | ||
module.exports() |
Sorry, the diff of this file is not supported yet
19098
13
577
110
+ Addedduplexer@0.0.1(transitive)
+ Addedevent-stream@2.2.3(transitive)
+ Addedmap-stream@0.0.1(transitive)
- Removedevent-stream@2.1.9(transitive)
Updatedevent-stream@~2.2