* Creates an object with the same keys as `object` and values generated by * running each own enumerable property of `object` through the callback. * The callback is bound to `thisArg` and invoked with three arguments; * (value, key, object). * * If a property name is provid
(object, callback, thisArg)
| 37749 | * // => { 'fred': 40, 'pebbles': 1 } |
| 37750 | */ |
| 37751 | function mapValues(object, callback, thisArg) { |
| 37752 | var result = {}; |
| 37753 | callback = lodash.createCallback(callback, thisArg, 3); |
| 37754 | |
| 37755 | forOwn(object, function(value, key, object) { |
| 37756 | result[key] = callback(value, key, object); |
| 37757 | }); |
| 37758 | return result; |
| 37759 | } |
| 37760 | |
| 37761 | /** |
| 37762 | * Recursively merges own enumerable properties of the source object(s), that |