From d6f1b164f7c6b40cc7ee2266f13ca5db61c331b9 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Thu, 15 Jan 2015 20:06:05 -0800 Subject: [PATCH] Optimize object path in `baseMergeDeep`. --- lodash.src.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lodash.src.js b/lodash.src.js index 4bd858c79..f544b39f6 100644 --- a/lodash.src.js +++ b/lodash.src.js @@ -2534,7 +2534,7 @@ if (isCommon) { result = srcValue; - if (isArray(srcValue) || isTypedArray(srcValue)) { + if (isLength(srcValue) && (isArray(srcValue) || isTypedArray(srcValue))) { result = isArray(value) ? value : []; } else if (isPlainObject(srcValue)) { result = isPlainObject(value) ? value : {};