Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

duplexify

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

duplexify - npm Package Compare versions

Comparing version 3.4.4 to 3.4.5

17

index.js
var stream = require('readable-stream')
var eos = require('end-of-stream')
var inherits = require('inherits')
var shift = require('stream-shift')

@@ -27,15 +28,2 @@ var SIGNAL_FLUSH = new Buffer([0])

var getStateLength = function(state) {
if (state.buffer.length) {
// Since node 6.3.0 state.buffer is a BufferList not an array
if (state.buffer.head) {
return state.buffer.head.data.length
}
return state.buffer[0].length
}
return state.length
}
var toStreams2 = function(rs) {

@@ -173,5 +161,4 @@ return new (stream.Readable)({objectMode:true, highWaterMark:16}).wrap(rs)

var data
var state = this._readable2._readableState
while ((data = this._readable2.read(getStateLength(state))) !== null) {
while ((data = shift(this._readable2)) !== null) {
this._drained = this.push(data)

@@ -178,0 +165,0 @@ }

5

package.json
{
"name": "duplexify",
"version": "3.4.4",
"version": "3.4.5",
"description": "Turn a writeable and readable stream into a streams2 duplex stream with support for async initialization and streams1/streams2 input",

@@ -9,3 +9,4 @@ "main": "index.js",

"inherits": "^2.0.1",
"readable-stream": "^2.0.0"
"readable-stream": "^2.0.0",
"stream-shift": "^1.0.0"
},

@@ -12,0 +13,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