mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-07 10:07:48 +00:00
Simplify _.overArgs.
This commit is contained in:
@@ -8733,13 +8733,12 @@
|
|||||||
var funcsLength = transforms.length;
|
var funcsLength = transforms.length;
|
||||||
return rest(function(args) {
|
return rest(function(args) {
|
||||||
var index = -1,
|
var index = -1,
|
||||||
length = nativeMin(args.length, funcsLength),
|
length = nativeMin(args.length, funcsLength);
|
||||||
newArgs = copyArray(args);
|
|
||||||
|
|
||||||
while (++index < length) {
|
while (++index < length) {
|
||||||
newArgs[index] = transforms[index].call(this, args[index]);
|
args[index] = transforms[index].call(this, args[index]);
|
||||||
}
|
}
|
||||||
return apply(func, this, newArgs);
|
return apply(func, this, args);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user