mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-01-31 15:27:50 +00:00
Bump to v3.5.0.
This commit is contained in:
@@ -46,7 +46,10 @@ define(['../internal/baseIndexOf', '../internal/binaryIndex'], function(baseInde
|
||||
var index = binaryIndex(array, value),
|
||||
other = array[index];
|
||||
|
||||
return (value === value ? value === other : other !== other) ? index : -1;
|
||||
if (value === value ? (value === other) : (other !== other)) {
|
||||
return index;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
return baseIndexOf(array, value, fromIndex || 0);
|
||||
}
|
||||
|
||||
@@ -40,7 +40,10 @@ define(['../internal/binaryIndex', '../internal/indexOfNaN'], function(binaryInd
|
||||
} else if (fromIndex) {
|
||||
index = binaryIndex(array, value, true) - 1;
|
||||
var other = array[index];
|
||||
return (value === value ? value === other : other !== other) ? index : -1;
|
||||
if (value === value ? (value === other) : (other !== other)) {
|
||||
return index;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
if (value !== value) {
|
||||
return indexOfNaN(array, index, true);
|
||||
|
||||
Reference in New Issue
Block a user