* The base implementation of `_.pickBy` without support for iteratee shorthands. * * @private * @param {Object} object The source object. * @param {string[]} paths The property paths to pick. * @param {Function} predicate The function invoked per property. * @returns {
(object, paths, predicate)
| 3819 | * @returns {Object} Returns the new object. |
| 3820 | */ |
| 3821 | function basePickBy(object, paths, predicate) { |
| 3822 | var index = -1, |
| 3823 | length = paths.length, |
| 3824 | result = {}; |
| 3825 | |
| 3826 | while (++index < length) { |
| 3827 | var path = paths[index], |
| 3828 | value = baseGet(object, path); |
| 3829 | |
| 3830 | if (predicate(value, path)) { |
| 3831 | baseSet(result, castPath(path, object), value); |
| 3832 | } |
| 3833 | } |
| 3834 | return result; |
| 3835 | } |
| 3836 | |
| 3837 | /** |
| 3838 | * A specialized version of `baseProperty` which supports deep paths. |