tjmehta/101

curry should not pass more args than specified

Closed this issue · 4 comments

var maxOf2 = curry(Math.max, 2);
maxOf2(10, 20, [1,2,3]); // should return 20, but currently returns NaN

@stoeffel I know this is not the main purpose of curry, but can curry be used to do the above?

can curry be used to do the above?

Currently not, but I'm not against changing the current behaviour to not pass more args than specified.

I will create a PR next weekend to change this.

Nice, yah I am overdue on some PRs on this going to handle them this wkend. Just finished up a project I've been working on so I should have time.