From 67d9656e358e91c9ea4045efcdcba554a44904b2 Mon Sep 17 00:00:00 2001 From: jdalton Date: Sun, 1 Feb 2015 20:05:56 -0800 Subject: [PATCH] Use `baseProperty` instead of `_.property` in more places. --- lodash.src.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lodash.src.js b/lodash.src.js index 697d47b8f..46997ebe7 100644 --- a/lodash.src.js +++ b/lodash.src.js @@ -6234,7 +6234,7 @@ * // => [36, 40] (iteration order is not guaranteed) */ function pluck(collection, key) { - return map(collection, property(key)); + return map(collection, baseProperty(key + '')); } /** @@ -10896,10 +10896,10 @@ // Add `LazyWrapper` methods for `_.pluck` and `_.where`. arrayEach(['pluck', 'where'], function(methodName, index) { var operationName = index ? 'filter' : 'map', - createCallback = index ? baseMatches : property; + createCallback = index ? baseMatches : baseProperty; LazyWrapper.prototype[methodName] = function(value) { - return this[operationName](createCallback(value)); + return this[operationName](createCallback(index ? value : (value + ''))); }; });