mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-09 18:37:50 +00:00
Ensure _.merge skips merging when object and source are the same value.
This commit is contained in:
@@ -2529,6 +2529,9 @@
|
||||
* @param {Array} [stackB=[]] Associates values with source counterparts.
|
||||
*/
|
||||
function baseMerge(object, source, customizer, stackA, stackB) {
|
||||
if (object === source) {
|
||||
return;
|
||||
}
|
||||
var props = (isArray(source) || isTypedArray(source)) ? undefined : keysIn(source);
|
||||
arrayEach(props || source, function(srcValue, key) {
|
||||
if (props) {
|
||||
|
||||
Reference in New Issue
Block a user