🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

pipe-functions

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pipe-functions - npm Package Compare versions

Comparing version

to
1.2.1

2

lib/pipe-non-es6.js

@@ -5,3 +5,3 @@ var pipe = function() {

let exec = v();
if (exec.then) {
if (exec && exec.then) {
return exec.then(v => f(v));

@@ -8,0 +8,0 @@ } else {

@@ -8,3 +8,3 @@ 'use strict';

let exec = v();
if (exec.then) {
if (exec && exec.then) {
return exec.then(v => f(v));

@@ -11,0 +11,0 @@ } else {

{
"name": "pipe-functions",
"version": "1.2.0",
"version": "1.2.1",
"description": "Pipe functions in a Unix-like style. It supports Promises (async) anywhere in the pipeline and every step will be executed sequentially. The return (resolve in case of Promises) of each function will be passed in as an argument to the next one",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/DiegoZoracKy/pipe-functions/",

@@ -20,2 +20,11 @@ /*globals describe, it*/

it(`should pass forward 'undefined' values`, function() {
const a = () => new Promise((resolve, reject) => setTimeout(() => resolve(undefined), 1000));;
const b = (x) => x + undefined;
const c = (x) => x + 'C';
assert(pipe(a, b, c));
});
});

@@ -32,3 +41,12 @@

it(`should pass forward 'undefined' values`, function() {
const a = () => undefined;
const b = (x) => x + undefined;
const c = (x) => x + 'C';
assert(pipe(a, b, c));
});
});
});

@@ -0,0 +0,0 @@ /*globals describe, it*/

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet