mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 09:47:48 +00:00
Bump to v4.7.0.
This commit is contained in:
@@ -7,10 +7,13 @@ var addSetEntry = require('./_addSetEntry'),
|
||||
*
|
||||
* @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);
|
||||
}
|
||||
|
||||
module.exports = cloneSet;
|
||||
|
||||
Reference in New Issue
Block a user