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

ordered-read-streams

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ordered-read-streams - npm Package Compare versions

Comparing version 0.0.5 to 0.0.6

18

index.js

@@ -24,3 +24,2 @@ var Readable = require('stream').Readable;

this._buff = {};
this._buffChinks = 0;
this._totalStreams = streams.length;

@@ -42,3 +41,2 @@ this._openedStreams = streams.length;

} else {
self._buffChinks++;
self._buff[i].push(data); // store in buffer for future

@@ -53,8 +51,9 @@ }

if (!--self._openedStreams) {
for (var i = self._currentIndex; i < self._totalStreams; i++) {
while (self._buff[i].length) {
self.push(self._buff[i].shift());
// flush buffered data (if any) before end
for (var j = 0; j < self._totalStreams; j++) {
while (self._buff[j].length) {
self.push(self._buff[j].shift());
}
}
self.push(null)
self.push(null);
}

@@ -74,9 +73,4 @@ });

OrderedStreams.prototype._read = function () {
var data = this._buff[this._currentIndex];
if (data.length) {
this.push(data);
}
};
OrderedStreams.prototype._read = function () {};
module.exports = OrderedStreams;
{
"name": "ordered-read-streams",
"version": "0.0.5",
"version": "0.0.6",
"description": "Combines array of streams into one read stream in strict order",

@@ -5,0 +5,0 @@ "main": "index.js",

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