mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-02 08:07:50 +00:00
Use var toIteratee instead of callback.
This commit is contained in:
committed by
John-David Dalton
parent
c51466935c
commit
5651993d93
@@ -3709,10 +3709,10 @@
|
||||
*/
|
||||
function createSortedIndex(retHighest) {
|
||||
return function(array, value, iteratee) {
|
||||
var callback = getIteratee();
|
||||
return (iteratee == null && callback === baseIteratee)
|
||||
var toIteratee = getIteratee();
|
||||
return (iteratee == null && toIteratee === baseIteratee)
|
||||
? binaryIndex(array, value, retHighest)
|
||||
: binaryIndexBy(array, value, callback(iteratee), retHighest);
|
||||
: binaryIndexBy(array, value, toIteratee(iteratee), retHighest);
|
||||
};
|
||||
}
|
||||
|
||||
@@ -5612,9 +5612,9 @@
|
||||
iteratee = isIterateeCall(array, isSorted, iteratee) ? undefined : isSorted;
|
||||
isSorted = false;
|
||||
}
|
||||
var callback = getIteratee();
|
||||
if (!(iteratee == null && callback === baseIteratee)) {
|
||||
iteratee = callback(iteratee);
|
||||
var toIteratee = getIteratee();
|
||||
if (!(iteratee == null && toIteratee === baseIteratee)) {
|
||||
iteratee = toIteratee(iteratee);
|
||||
}
|
||||
return (isSorted && getIndexOf() === baseIndexOf)
|
||||
? sortedUniq(array, iteratee)
|
||||
|
||||
Reference in New Issue
Block a user