Files
lodash/_basePick.js
John-David Dalton c7a7540e16 Bump to v4.17.3.
2016-12-21 15:46:13 -06:00

20 lines
517 B
JavaScript

define(['./_basePickBy', './hasIn'], function(basePickBy, hasIn) {
/**
* The base implementation of `_.pick` without support for individual
* property identifiers.
*
* @private
* @param {Object} object The source object.
* @param {string[]} paths The property paths to pick.
* @returns {Object} Returns the new object.
*/
function basePick(object, paths) {
return basePickBy(object, paths, function(value, path) {
return hasIn(object, path);
});
}
return basePick;
});