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

stream-via

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stream-via - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

9

lib/stream-via.js

@@ -18,3 +18,5 @@ 'use strict'

function via (throughFunction, options) {
options = options || {}
var stream = Transform(options)
stream._transform = function (chunk, enc, done) {

@@ -30,2 +32,9 @@ if (chunk) {

}
/* node 0.10 polyfil */
if (!options.objectMode) {
if (options.readableObjectMode) stream._readableState.objectMode = true
if (options.writableObjectMode) stream._writableState.objectMode = true
}
return stream

@@ -32,0 +41,0 @@ }

2

package.json
{
"name": "stream-via",
"author": "Lloyd Brookes <75pound@gmail.com>",
"version": "1.0.2",
"version": "1.0.3",
"description": "stream-via",

@@ -6,0 +6,0 @@ "repository": "https://github.com/75lb/stream-via.git",

@@ -94,1 +94,13 @@ var test = require('tape')

})
test('via: readableObjectMode', function (t) {
var stream = via(
function (buf) {
t.strictEqual(buf.toString(), 'yeah')
return {}
},
{ readableObjectMode: true }
)
stream.end('yeah')
t.end()
})
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