867d722e5aebdba895bb86f9ed3/node_modules/lodash/fp/forOwn.js" class="text truncate">forOwn.js 11e3a9652a first 7 年 前 forOwnRight.js 11e3a9652a first 7 年 前 fromPairs.js 11e3a9652a first 7 年 前 function.js 11e3a9652a first 7 年 前 functions.js 11e3a9652a first 7 年 前 functionsIn.js 11e3a9652a first 7 年 前 get.js 11e3a9652a first 7 年 前 getOr.js 11e3a9652a first 7 年 前 groupBy.js 11e3a9652a first 7 年 前 gt.js 11e3a9652a first 7 年 前 gte.js 11e3a9652a first 7 年 前 has.js 11e3a9652a first 7 年 前 hasIn.js 11e3a9652a first 7 年 前 head.js 11e3a9652a first 7 年 前 identical.js 11e3a9652a first 7 年 前 identity.js 11e3a9652a first 7 年 前 inRange.js 11e3a9652a first 7 年 前 includes.js 11e3a9652a first 7 年 前 includesFrom.js 11e3a9652a first 7 年 前 indexBy.js 11e3a9652a first 7 年 前 indexOf.js 11e3a9652a first 7 年 前 indexOfFrom.js 11e3a9652a first 7 年 前 init.js 11e3a9652a first 7 年 前 initial.js 11e3a9652a first 7 年 前 intersection.js 11e3a9652a first 7 年 前 intersectionBy.js 11e3a9652a first 7 年 前 intersectionWith.js 11e3a9652a first 7 年 前 invert.js 11e3a9652a first 7 年 前 invertBy.js 11e3a9652a first 7 年 前 invertObj.js 11e3a9652a first 7 年 前 invoke.js 11e3a9652a first 7 年 前 invokeArgs.js 11e3a9652a first 7 年 前 invokeArgsMap.js 11e3a9652a first 7 年 前 invokeMap.js 11e3a9652a first 7 年 前 isArguments.js 11e3a9652a first 7 年 前 isArray.js 11e3a9652a first 7 年 前 isArrayBuffer.js 11e3a9652a first 7 年 前 isArrayLike.js 11e3a9652a first 7 年 前 isArrayLikeObject.js 11e3a9652a first 7 年 前 isBoolean.js 11e3a9652a first 7 年 前 isBuffer.js 11e3a9652a first 7 年 前 isDate.js 11e3a9652a first 7 年 前 isElement.js 11e3a9652a first 7 年 前 isEmpty.js 11e3a9652a first 7 年 前 isEqual.js 11e3a9652a first 7 年 前 isEqualWith.js 11e3a9652a first 7 年 前 isError.js 11e3a9652a first 7 年 前 isFinite.js 11e3a9652a first 7 年 前 isFunction.js 11e3a9652a first 7 年 前 isInteger.js 11e3a9652a first 7 年 前 isLength.js 11e3a9652a first 7 年 前 isMap.js 11e3a9652a first 7 年 前 isMatch.js 11e3a9652a first 7 年 前 isMatchWith.js 11e3a9652a first 7 年 前 isNaN.js 11e3a9652a first 7 年 前 isNative.js 11e3a9652a first 7 年 前 isNil.js 11e3a9652a first 7 年 前 isNull.js 11e3a9652a first 7 年 前 isNumber.js 11e3a9652a first 7 年 前 isObject.js 11e3a9652a first 7 年 前 isObjectLike.js 11e3a9652a first 7 年 前 isPlainObject.js 11e3a9652a first 7 年 前 isRegExp.js 11e3a9652a first 7 年 前 isSafeInteger.js 11e3a9652a first 7 年 前 isSet.js 11e3a9652a first 7 年 前 isString.js 11e3a9652a first 7 年 前 isSymbol.js 11e3a9652a first 7 年 前 isTypedArray.js 11e3a9652a first 7 年 前 isUndefined.js 11e3a9652a first 7 年 前 isWeakMap.js 11e3a9652a first 7 年 前 isWeakSet.js 11e3a9652a first 7 年 前 iteratee.js 11e3a9652a first 7 年 前 join.js 11e3a9652a first 7 年 前 juxt.js 11e3a9652a first 7 年 前 kebabCase.js 11e3a9652a first 7 年 前 keyBy.js 11e3a9652a first 7 年 前 keys.js 11e3a9652a first 7 年 前 keysIn.js 11e3a9652a first 7 年 前 lang.js 11e3a9652a first 7 年 前 last.js 11e3a9652a first 7 年 前 lastIndexOf.js 11e3a9652a first 7 年 前 lastIndexOfFrom.js 11e3a9652a first 7 年 前 lowerCase.js 11e3a9652a first 7 年 前 lowerFirst.js 11e3a9652a first 7 年 前 lt.js 11e3a9652a first 7 年 前 lte.js 11e3a9652a first 7 年 前 map.js 11e3a9652a first 7 年 前 mapKeys.js 11e3a9652a first 7 年 前 mapValues.js 11e3a9652a first 7 年 前 matches.js 11e3a9652a first 7 年 前 matchesProperty.js 11e3a9652a first 7 年 前 math.js 11e3a9652a first 7 年 前 max.js 11e3a9652a first 7 年 前 maxBy.js 11e3a9652a first 7 年 前 mean.js 11e3a9652a first 7 年 前 meanBy.js 11e3a9652a first 7 年 前 memoize.js 11e3a9652a first 7 年 前 merge.js 11e3a9652a first 7 年 前 mergeAll.js 11e3a9652a first 7 年 前 mergeAllWith.js 11e3a9652a first 7 年 前 mergeWith.js 11e3a9652a first 7 年 前 method.js 11e3a9652a first 7 年 前 methodOf.js 11e3a9652a first 7 年 前 min.js 11e3a9652a first 7 年 前 minBy.js 11e3a9652a first 7 年 前 mixin.js 11e3a9652a first 7 年 前 multiply.js 11e3a9652a first 7 年 前 nAry.js 11e3a9652a first 7 年 前 negate.js 11e3a9652a first 7 年 前 next.js 11e3a9652a first 7 年 前 noop.js 11e3a9652a first 7 年 前 now.js 11e3a9652a first 7 年 前 nth.js 11e3a9652a first 7 年 前 nthArg.js 11e3a9652a first 7 年 前 number.js 11e3a9652a first 7 年 前 object.js 11e3a9652a first 7 年 前 omit.js 11e3a9652a first 7 年 前 omitAll.js 11e3a9652a first 7 年 前 omitBy.js 11e3a9652a first 7 年 前 once.js 11e3a9652a first 7 年 前 orderBy.js 11e3a9652a first 7 年 前 over.js 11e3a9652a first 7 年 前 overArgs.js 11e3a9652a first 7 年 前 overEvery.js 11e3a9652a first 7 年 前 overSome.js 11e3a9652a first 7 年 前 pad.js 11e3a9652a first 7 年 前 padChars.js 11e3a9652a first 7 年 前 padCharsEnd.js 11e3a9652a first 7 年 前 padCharsStart.js 11e3a9652a first 7 年 前 padEnd.js 11e3a9652a first 7 年 前 padStart.js 11e3a9652a first 7 年 前 parseInt.js 11e3a9652a first 7 年 前 partial.js 11e3a9652a first 7 年 前 partialRight.js 11e3a9652a first 7 年 前 partition.js 11e3a9652a first 7 年 前 path.js 11e3a9652a first 7 年 前 pathEq.js 11e3a9652a first 7 年 前 pathOr.js 11e3a9652a first 7 年 前 paths.js 11e3a9652a first 7 年 前 pick.js 11e3a9652a first 7 年 前 pickAll.js 11e3a9652a first 7 年 前 pickBy.js 11e3a9652a first 7 年 前 pipe.js 11e3a9652a first 7 年 前 placeholder.js 11e3a9652a first 7 年 前 plant.js 11e3a9652a first 7 年 前 pluck.js 11e3a9652a first 7 年 前 prop.js 11e3a9652a first 7 年 前 propEq.js 11e3a9652a first 7 年 前 propOr.js 11e3a9652a first 7 年 前 property.js 11e3a9652a first 7 年 前 propertyOf.js 11e3a9652a first 7 年 前 props.js 11e3a9652a first 7 年 前 pull.js 11e3a9652a first 7 年 前 pullAll.js 11e3a9652a first 7 年 前 pullAllBy.js 11e3a9652a first 7 年 前 pullAllWith.js 11e3a9652a first 7 年 前 pullAt.js 11e3a9652a first 7 年 前 random.js 11e3a9652a first 7 年 前 range.js 11e3a9652a first 7 年 前 rangeRight.js 11e3a9652a first 7 年 前 rangeStep.js 11e3a9652a first 7 年 前 rangeStepRight.js 11e3a9652a first 7 年 前 rearg.js 11e3a9652a first 7 年 前 reduce.js 11e3a9652a first 7 年 前 reduceRight.js 11e3a9652a first 7 年 前 reject.js 11e3a9652a first 7 年 前 remove.js 11e3a9652a first 7 年 前 repeat.js 11e3a9652a first 7 年 前 replace.js 11e3a9652a first 7 年 前 rest.js 11e3a9652a first 7 年 前 restFrom.js 11e3a9652a first 7 年 前 result.js 11e3a9652a first 7 年 前 reverse.js 11e3a9652a first 7 年 前 round.js 11e3a9652a first 7 年 前 sample.js 11e3a9652a first 7 年 前 sampleSize.js 11e3a9652a first 7 年 前 seq.js 11e3a9652a first 7 年 前 set.js 11e3a9652a first 7 年 前 setWith.js 11e3a9652a first 7 年 前 shuffle.js 11e3a9652a first 7 年 前 size.js 11e3a9652a first 7 年 前 slice.js 11e3a9652a first 7 年 前 snakeCase.js 11e3a9652a first 7 年 前 some.js 11e3a9652a first 7 年 前 sortBy.js 11e3a9652a first 7 年 前 sortedIndex.js 11e3a9652a first 7 年 前 sortedIndexBy.js 11e3a9652a first 7 年 前 sortedIndexOf.js 11e3a9652a first 7 年 前 sortedLastIndex.js 11e3a9652a first 7 年 前 sortedLastIndexBy.js 11e3a9652a first 7 年 前 sortedLastIndexOf.js 11e3a9652a first 7 年 前 sortedUniq.js 11e3a9652a first 7 年 前 sortedUniqBy.js 11e3a9652a first 7 年 前 split.js 11e3a9652a first 7 年 前 spread.js 11e3a9652a first 7 年 前 spreadFrom.js 11e3a9652a first 7 年 前 startCase.js 11e3a9652a first 7 年 前 startsWith.js 11e3a9652a first 7 年 前 string.js 11e3a9652a first 7 年 前 stubArray.js 11e3a9652a first 7 年 前 stubFalse.js 11e3a9652a first 7 年 前 stubObject.js 11e3a9652a first 7 年 前 stubString.js 11e3a9652a first 7 年 前 stubTrue.js 11e3a9652a first 7 年 前 subtract.js 11e3a9652a first 7 年 前 sum.js 11e3a9652a first 7 年 前 sumBy.js 11e3a9652a first 7 年 前 symmetricDifference.js 11e3a9652a first 7 年 前 symmetricDifferenceBy.js 11e3a9652a first 7 年 前 symmetricDifferenceWith.js 11e3a9652a first 7 年 前 tail.js 11e3a9652a first 7 年 前 take.js 11e3a9652a first 7 年 前 takeLast.js 11e3a9652a first 7 年 前 takeLastWhile.js 11e3a9652a first 7 年 前 takeRight.js 11e3a9652a first 7 年 前 takeRightWhile.js 11e3a9652a first 7 年 前 takeWhile.js 11e3a9652a first 7 年 前 tap.js 11e3a9652a first 7 年 前 template.js 11e3a9652a first 7 年 前 templateSettings.js 11e3a9652a first 7 年 前 throttle.js 11e3a9652a first 7 年 前 thru.js 11e3a9652a first 7 年 前 times.js 11e3a9652a first 7 年 前 toArray.js 11e3a9652a first 7 年 前 toFinite.js 11e3a9652a first 7 年 前 toInteger.js 11e3a9652a first 7 年 前 toIterator.js 11e3a9652a first 7 年 前 toJSON.js 11e3a9652a first 7 年 前 toLength.js 11e3a9652a first 7 年 前 toLower.js 11e3a9652a first 7 年 前 toNumber.js 11e3a9652a first 7 年 前 toPairs.js 11e3a9652a first 7 年 前 toPairsIn.js 11e3a9652a first 7 年 前 toPath.js 11e3a9652a first 7 年 前 toPlainObject.js 11e3a9652a first 7 年 前 toSafeInteger.js 11e3a9652a first 7 年 前 toString.js 11e3a9652a first 7 年 前 toUpper.js 11e3a9652a first 7 年 前 transform.js 11e3a9652a first 7 年 前 trim.js 11e3a9652a first 7 年 前 trimChars.js 11e3a9652a first 7 年 前 trimCharsEnd.js 11e3a9652a first 7 年 前 trimCharsStart.js 11e3a9652a first 7 年 前 trimEnd.js 11e3a9652a first 7 年 前 trimStart.js 11e3a9652a first 7 年 前 truncate.js 11e3a9652a first 7 年 前 unapply.js 11e3a9652a first 7 年 前 unary.js 11e3a9652a first 7 年 前 unescape.js 11e3a9652a first 7 年 前 union.js 11e3a9652a first 7 年 前 unionBy.js 11e3a9652a first 7 年 前 unionWith.js 11e3a9652a first 7 年 前 uniq.js 11e3a9652a first 7 年 前 uniqBy.js 11e3a9652a first 7 年 前 uniqWith.js 11e3a9652a first 7 年 前 uniqueId.js 11e3a9652a first 7 年 前 unnest.js 11e3a9652a first 7 年 前 unset.js 11e3a9652a first 7 年 前 unzip.js 11e3a9652a first 7 年 前 unzipWith.js 11e3a9652a first 7 年 前 update.js 11e3a9652a first 7 年 前 updateWith.js 11e3a9652a first 7 年 前 upperCase.js 11e3a9652a first 7 年 前 upperFirst.js 11e3a9652a first 7 年 前 useWith.js 11e3a9652a first 7 年 前 util.js 11e3a9652a first 7 年 前 value.js 11e3a9652a first 7 年 前 valueOf.js 11e3a9652a first 7 年 前 values.js 11e3a9652a first 7 年 前 valuesIn.js 11e3a9652a first 7 年 前 where.js 11e3a9652a first 7 年 前 whereEq.js 11e3a9652a first 7 年 前 without.js 11e3a9652a first 7 年 前 words.js 11e3a9652a first 7 年 前 wrap.js 11e3a9652a first 7 年 前 wrapperAt.js 11e3a9652a first 7 年 前 wrapperChain.js 11e3a9652a first 7 年 前 wrapperLodash.js 11e3a9652a first 7 年 前 wrapperReverse.js 11e3a9652a first 7 年 前 wrapperValue.js 11e3a9652a first 7 年 前 xor.js 11e3a9652a first 7 年 前 xorBy.js 11e3a9652a first 7 年 前 xorWith.js 11e3a9652a first 7 年 前 zip.js 11e3a9652a first 7 年 前 zipAll.js 11e3a9652a first 7 年 前 zipObj.js 11e3a9652a first 7 年 前 zipObject.js 11e3a9652a first 7 年 前 zipObjectDeep.js 11e3a9652a first 7 年 前 zipWith.js 11e3a9652a first 7 年 前 adminSystem - Gogs: Go Git Service

Aucune description

_baseClone.js 5.5KB

    var Stack = require('./_Stack'), arrayEach = require('./_arrayEach'), assignValue = require('./_assignValue'), baseAssign = require('./_baseAssign'), baseAssignIn = require('./_baseAssignIn'), cloneBuffer = require('./_cloneBuffer'), copyArray = require('./_copyArray'), copySymbols = require('./_copySymbols'), copySymbolsIn = require('./_copySymbolsIn'), getAllKeys = require('./_getAllKeys'), getAllKeysIn = require('./_getAllKeysIn'), getTag = require('./_getTag'), initCloneArray = require('./_initCloneArray'), initCloneByTag = require('./_initCloneByTag'), initCloneObject = require('./_initCloneObject'), isArray = require('./isArray'), isBuffer = require('./isBuffer'), isMap = require('./isMap'), isObject = require('./isObject'), isSet = require('./isSet'), keys = require('./keys'); /** Used to compose bitmasks for cloning. */ var CLONE_DEEP_FLAG = 1, CLONE_FLAT_FLAG = 2, CLONE_SYMBOLS_FLAG = 4; /** `Object#toString` result references. */ var argsTag = '[object Arguments]', arrayTag = '[object Array]', boolTag = '[object Boolean]', dateTag = '[object Date]', errorTag = '[object Error]', funcTag = '[object Function]', genTag = '[object GeneratorFunction]', mapTag = '[object Map]', numberTag = '[object Number]', objectTag = '[object Object]', regexpTag = '[object RegExp]', setTag = '[object Set]', stringTag = '[object String]', symbolTag = '[object Symbol]', weakMapTag = '[object WeakMap]'; var arrayBufferTag = '[object ArrayBuffer]', dataViewTag = '[object DataView]', float32Tag = '[object Float32Array]', float64Tag = '[object Float64Array]', int8Tag = '[object Int8Array]', int16Tag = '[object Int16Array]', int32Tag = '[object Int32Array]', uint8Tag = '[object Uint8Array]', uint8ClampedTag = '[object Uint8ClampedArray]', uint16Tag = '[object Uint16Array]', uint32Tag = '[object Uint32Array]'; /** Used to identify `toStringTag` values supported by `_.clone`. */ var cloneableTags = {}; cloneableTags[argsTag] = cloneableTags[arrayTag] = cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] = cloneableTags[boolTag] = cloneableTags[dateTag] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag] = cloneableTags[numberTag] = cloneableTags[objectTag] = cloneableTags[regexpTag] = cloneableTags[setTag] = cloneableTags[stringTag] = cloneableTags[symbolTag] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true; cloneableTags[errorTag] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = false; /** * The base implementation of `_.clone` and `_.cloneDeep` which tracks * traversed objects. * * @private * @param {*} value The value to clone. * @param {boolean} bitmask The bitmask flags. * 1 - Deep clone * 2 - Flatten inherited properties * 4 - Clone symbols * @param {Function} [customizer] The function to customize cloning. * @param {string} [key] The key of `value`. * @param {Object} [object] The parent object of `value`. * @param {Object} [stack] Tracks traversed objects and their clone counterparts. * @returns {*} Returns the cloned value. */ function baseClone(value, bitmask, customizer, key, object, stack) { var result, isDeep = bitmask & CLONE_DEEP_FLAG, isFlat = bitmask & CLONE_FLAT_FLAG, isFull = bitmask & CLONE_SYMBOLS_FLAG; if (customizer) { result = object ? customizer(value, key, object, stack) : customizer(value); } if (result !== undefined) { return result; } if (!isObject(value)) { return value; } var isArr = isArray(value); if (isArr) { result = initCloneArray(value); if (!isDeep) { return copyArray(value, result); } } else { var tag = getTag(value), isFunc = tag == funcTag || tag == genTag; if (isBuffer(value)) { return cloneBuffer(value, isDeep); } if (tag == objectTag || tag == argsTag || (isFunc && !object)) { result = (isFlat || isFunc) ? {} : initCloneObject(value); if (!isDeep) { return isFlat ? copySymbolsIn(value, baseAssignIn(result, value)) : copySymbols(value, baseAssign(result, value)); } } else { if (!cloneableTags[tag]) { return object ? value : {}; } result = initCloneByTag(value, tag, isDeep); } } // Check for circular references and return its corresponding clone. stack || (stack = new Stack); var stacked = stack.get(value); if (stacked) { return stacked; } stack.set(value, result); if (isSet(value)) { value.forEach(function(subValue) { result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack)); }); return result; } if (isMap(value)) { value.forEach(function(subValue, key) { result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack)); }); return result; } var keysFunc = isFull ? (isFlat ? getAllKeysIn : getAllKeys) : (isFlat ? keysIn : keys); var props = isArr ? undefined : keysFunc(value); arrayEach(props || value, function(subValue, key) { if (props) { key = subValue; subValue = value[key]; } // Recursively populate clone (susceptible to call stack limits). assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack)); }); return result; } module.exports = baseClone;