* Creates a duplicate-value-free version of an array using strict equality * for comparisons, i.e. `===`. If the array is sorted, providing * `true` for `isSorted` will use a faster algorithm. If a callback is provided * each element of `array` is passed through the callback before un
(array, isSorted, callback, thisArg)
| 40114 | * // => [{ 'x': 1 }, { 'x': 2 }] |
| 40115 | */ |
| 40116 | function uniq(array, isSorted, callback, thisArg) { |
| 40117 | // juggle arguments |
| 40118 | if (typeof isSorted != 'boolean' && isSorted != null) { |
| 40119 | thisArg = callback; |
| 40120 | callback = (typeof isSorted != 'function' && thisArg && thisArg[isSorted] === array) ? null : isSorted; |
| 40121 | isSorted = false; |
| 40122 | } |
| 40123 | if (callback != null) { |
| 40124 | callback = lodash.createCallback(callback, thisArg, 3); |
| 40125 | } |
| 40126 | return baseUniq(array, isSorted, callback); |
| 40127 | } |
| 40128 | |
| 40129 | /** |
| 40130 | * Creates an array excluding all provided values using strict equality for |
nothing calls this directly
no test coverage detected