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

memorystream

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

memorystream - npm Package Compare versions

Comparing version 0.3.0 to 0.3.1

5

index.js

@@ -51,2 +51,3 @@ 'use strict';

});
}

@@ -108,3 +109,2 @@

wait_data = this instanceof STREAM.Duplex && ! this._writableState.finished ? true : false;
if ( ! this.queue.length && ! wait_data) {

@@ -149,2 +149,5 @@ this.push(null);// finish stream

if (this instanceof STREAM.Duplex) {
while (this.queue.length) {
this.push(this.queue.shift());
}
this.push(decoded_chunk);

@@ -151,0 +154,0 @@ } else {

2

package.json
{
"name": "memorystream",
"description": "This is lightweight memory stream module for node.js.",
"version": "0.3.0",
"version": "0.3.1",
"keywords": [

@@ -6,0 +6,0 @@ "memory",

@@ -279,2 +279,25 @@ var MemoryStream = require('../index.js'),

});
it("should write/read data with init buffer", function (done) {
var l = Math.floor(test_data.length / 2);
var test_data1 = test_data.substr(0, l),
test_data2 = test_data.substr(l);
var mem_stream = new MemoryStream(test_data1.split(''));
var data = '';
mem_stream.on('data',function(chunk){
data += chunk;
});
writeToStream2(mem_stream, test_data2);
mem_stream.on('end', function() {
expect(data).to.be(test_data);
done();
});
});

@@ -281,0 +304,0 @@

Sorry, the diff of this file is not supported yet

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