chickencurry
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -35,5 +35,5 @@ var merge = require('./lib/merge'), | ||
return curry(fn, length + 1, args); | ||
return curry(fn, length, args); | ||
}; | ||
module.exports.__ = __; |
{ | ||
"name": "chickencurry", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "Add some chicken curry to your functions", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -57,3 +57,3 @@ Chickencurry | ||
// Curry n arguments | ||
curry.n(join, 2)(1, 2)(3) // => '1,2,3' | ||
curry.n(join, 3)(1, 2)(3) // => '1,2,3' | ||
``` | ||
@@ -60,0 +60,0 @@ |
12
test.js
@@ -147,9 +147,9 @@ var curry = require('./index.js'), | ||
it('should curry n arguments', () => { | ||
expect(curry.n(joinArgs, 0)(4)).to.equal('4'); | ||
expect(curry.n(joinArgs, 1)(1, 2)).to.equal('1,2'); | ||
expect(curry.n(joinArgs, 3)(1, 2, 3)(4)).to.equal('1,2,3,4'); | ||
expect(curry.n(joinArgs, 3)(1)(2)(3)(4)).to.equal('1,2,3,4'); | ||
expect(curry.n(joinArgs, 3, 1, 2, 3)(4)).to.equal('1,2,3,4'); | ||
expect(curry.n(joinArgs, 3, void 0, 2, 3, 4)(0)).to.equal('0,2,3,4'); | ||
expect(curry.n(joinArgs, 1)(4)).to.equal('4'); | ||
expect(curry.n(joinArgs, 2)(1, 2)).to.equal('1,2'); | ||
expect(curry.n(joinArgs, 4)(1, 2, 3)(4)).to.equal('1,2,3,4'); | ||
expect(curry.n(joinArgs, 4)(1)(2)(3)(4)).to.equal('1,2,3,4'); | ||
expect(curry.n(joinArgs, 4, 1, 2, 3)(4)).to.equal('1,2,3,4'); | ||
expect(curry.n(joinArgs, 4, void 0, 2, 3, 4)(0)).to.equal('0,2,3,4'); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
10576