mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-02 08:07:50 +00:00
Bump to v4.7.0.
This commit is contained in:
@@ -5,10 +5,13 @@ define(['./_addSetEntry', './_arrayReduce', './_setToArray'], function(addSetEnt
|
||||
*
|
||||
* @private
|
||||
* @param {Object} set The set to clone.
|
||||
* @param {Function} cloneFunc The function to clone values.
|
||||
* @param {boolean} [isDeep] Specify a deep clone.
|
||||
* @returns {Object} Returns the cloned set.
|
||||
*/
|
||||
function cloneSet(set) {
|
||||
return arrayReduce(setToArray(set), addSetEntry, new set.constructor);
|
||||
function cloneSet(set, isDeep, cloneFunc) {
|
||||
var array = isDeep ? cloneFunc(setToArray(set), true) : setToArray(set);
|
||||
return arrayReduce(array, addSetEntry, new set.constructor);
|
||||
}
|
||||
|
||||
return cloneSet;
|
||||
|
||||
Reference in New Issue
Block a user