Bump to v4.13.1.

This commit is contained in:
John-David Dalton
2016-05-23 08:55:37 -07:00
parent 0cf3476f14
commit 295d8cf415
10 changed files with 229 additions and 171 deletions

View File

@@ -1,6 +1,5 @@
var findLastIndex = require('./findLastIndex'),
isArrayLike = require('./isArrayLike'),
values = require('./values');
var createFind = require('./_createFind'),
findLastIndex = require('./findLastIndex');
/**
* This method is like `_.find` except that it iterates over elements of
@@ -22,10 +21,6 @@ var findLastIndex = require('./findLastIndex'),
* });
* // => 3
*/
function findLast(collection, predicate, fromIndex) {
collection = isArrayLike(collection) ? collection : values(collection);
var index = findLastIndex(collection, predicate, fromIndex);
return index > -1 ? collection[index] : undefined;
}
var findLast = createFind(findLastIndex);
module.exports = findLast;