Files
lodash/internal/basePropertyDeep.js
John-David Dalton fec213a98c Bump to v3.7.0.
2015-12-16 17:49:35 -08:00

20 lines
492 B
JavaScript

define(['./baseGet', './toPath'], function(baseGet, toPath) {
/**
* A specialized version of `baseProperty` which supports deep paths.
*
* @private
* @param {Array|string} path The path of the property to get.
* @returns {Function} Returns the new function.
*/
function basePropertyDeep(path) {
var pathKey = (path + '');
path = toPath(path);
return function(object) {
return baseGet(object, path, pathKey);
};
}
return basePropertyDeep;
});