PATH:
usr
/
local
/
lib
/
node_modules
/
bower
/
lib
/
node_modules
/
inquirer
/
node_modules
/
lodash
/
internal
var baseCreate = require('./baseCreate'), isObject = require('../lang/isObject'); /** * Creates a function that produces an instance of `Ctor` regardless of * whether it was invoked as part of a `new` expression or by `call` or `apply`. * * @private * @param {Function} Ctor The constructor to wrap. * @returns {Function} Returns the new wrapped function. */ function createCtorWrapper(Ctor) { return function() { // Use a `switch` statement to work with class constructors. // See http://ecma-international.org/ecma-262/6.0/#sec-ecmascript-function-objects-call-thisargument-argumentslist // for more details. var args = arguments; switch (args.length) { case 0: return new Ctor; case 1: return new Ctor(args[0]); case 2: return new Ctor(args[0], args[1]); case 3: return new Ctor(args[0], args[1], args[2]); case 4: return new Ctor(args[0], args[1], args[2], args[3]); case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]); case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]); case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]); } var thisBinding = baseCreate(Ctor.prototype), result = Ctor.apply(thisBinding, args); // Mimic the constructor's `return` behavior. // See https://es5.github.io/#x13.2.2 for more details. return isObject(result) ? result : thisBinding; }; } module.exports = createCtorWrapper;
[-] cacheIndexOf.js
[edit]
[-] charsLeftIndex.js
[edit]
[-] baseWrapperValue.js
[edit]
[-] shimKeys.js
[edit]
[-] createForOwn.js
[edit]
[-] deburrLetter.js
[edit]
[-] arrayEvery.js
[edit]
[-] baseFilter.js
[edit]
[-] getMatchData.js
[edit]
[-] isIterateeCall.js
[edit]
[-] arrayEach.js
[edit]
[-] createDefaults.js
[edit]
[-] mergeDefaults.js
[edit]
[-] baseForRight.js
[edit]
[-] baseValues.js
[edit]
[-] baseEachRight.js
[edit]
[-] baseFor.js
[edit]
[-] arraySum.js
[edit]
[-] createCompounder.js
[edit]
[-] baseForOwnRight.js
[edit]
[-] baseCompareAscending.js
[edit]
[-] baseWhile.js
[edit]
[-] baseDelay.js
[edit]
[-] metaMap.js
[edit]
[-] MapCache.js
[edit]
[-] arraySome.js
[edit]
[-] baseFindIndex.js
[edit]
[-] baseMatchesProperty.js
[edit]
[-] baseSortBy.js
[edit]
[-] baseRandom.js
[edit]
[-] baseDifference.js
[edit]
[-] compareAscending.js
[edit]
[-] LodashWrapper.js
[edit]
[-] invokePath.js
[edit]
[+]
..
[-] baseMap.js
[edit]
[-] isLaziable.js
[edit]
[-] unescapeHtmlChar.js
[edit]
[-] initCloneByTag.js
[edit]
[-] baseReduce.js
[edit]
[-] lazyReverse.js
[edit]
[-] baseUniq.js
[edit]
[-] baseGet.js
[edit]
[-] createReduce.js
[edit]
[-] cachePush.js
[edit]
[-] baseSum.js
[edit]
[-] escapeHtmlChar.js
[edit]
[-] mapHas.js
[edit]
[-] baseMatches.js
[edit]
[-] mapDelete.js
[edit]
[-] createCache.js
[edit]
[-] isArrayLike.js
[edit]
[-] toObject.js
[edit]
[-] basePropertyDeep.js
[edit]
[-] arrayFilter.js
[edit]
[-] assignWith.js
[edit]
[-] composeArgsRight.js
[edit]
[-] binaryIndex.js
[edit]
[-] mapSet.js
[edit]
[-] bindCallback.js
[edit]
[-] createExtremum.js
[edit]
[-] baseFunctions.js
[edit]
[-] baseToString.js
[edit]
[-] baseIsEqualDeep.js
[edit]
[-] createCtorWrapper.js
[edit]
[-] sortedUniq.js
[edit]
[-] arrayExtremum.js
[edit]
[-] baseExtremum.js
[edit]
[-] basePullAt.js
[edit]
[-] LazyWrapper.js
[edit]
[-] isStrictComparable.js
[edit]
[-] createBindWrapper.js
[edit]
[-] isObjectLike.js
[edit]
[-] createRound.js
[edit]
[-] getView.js
[edit]
[-] createAggregator.js
[edit]
[-] createFindKey.js
[edit]
[-] createBaseFor.js
[edit]
[-] getFuncName.js
[edit]
[-] trimmedRightIndex.js
[edit]
[-] isIndex.js
[edit]
[-] reEvaluate.js
[edit]
[-] reEscape.js
[edit]
[-] baseLodash.js
[edit]
[-] arrayConcat.js
[edit]
[-] escapeRegExpChar.js
[edit]
[-] baseIsFunction.js
[edit]
[-] baseForIn.js
[edit]
[-] toPath.js
[edit]
[-] arrayReduceRight.js
[edit]
[-] baseSortByOrder.js
[edit]
[-] baseSetData.js
[edit]
[-] arrayEachRight.js
[edit]
[-] baseFill.js
[edit]
[-] arrayMap.js
[edit]
[-] compareMultiple.js
[edit]
[-] mergeData.js
[edit]
[-] mapGet.js
[edit]
[-] createHybridWrapper.js
[edit]
[-] baseIndexOf.js
[edit]
[-] arrayPush.js
[edit]
[-] createCurry.js
[edit]
[-] realNames.js
[edit]
[-] arrayCopy.js
[edit]
[-] getNative.js
[edit]
[-] createPadding.js
[edit]
[-] charsRightIndex.js
[edit]
[-] baseCopy.js
[edit]
[-] baseCallback.js
[edit]
[-] pickByCallback.js
[edit]
[-] baseMerge.js
[edit]
[-] assignOwnDefaults.js
[edit]
[-] toIterable.js
[edit]
[-] baseCreate.js
[edit]
[-] initCloneArray.js
[edit]
[-] escapeStringChar.js
[edit]
[-] baseMergeDeep.js
[edit]
[-] createAssigner.js
[edit]
[-] createForEach.js
[edit]
[-] baseSome.js
[edit]
[-] trimmedLeftIndex.js
[edit]
[-] createFindIndex.js
[edit]
[-] arrayReduce.js
[edit]
[-] baseClone.js
[edit]
[-] isLength.js
[edit]
[-] indexOfNaN.js
[edit]
[-] createFlow.js
[edit]
[-] equalByTag.js
[edit]
[-] createWrapper.js
[edit]
[-] baseEach.js
[edit]
[-] composeArgs.js
[edit]
[-] equalObjects.js
[edit]
[-] baseFlatten.js
[edit]
[-] binaryIndexBy.js
[edit]
[-] assignDefaults.js
[edit]
[-] wrapperClone.js
[edit]
[-] createPadDir.js
[edit]
[-] isSpace.js
[edit]
[-] baseAssign.js
[edit]
[-] baseEvery.js
[edit]
[-] baseIsMatch.js
[edit]
[-] SetCache.js
[edit]
[-] replaceHolders.js
[edit]
[-] createObjectMapper.js
[edit]
[-] lazyClone.js
[edit]
[-] reInterpolate.js
[edit]
[-] bufferClone.js
[edit]
[-] createPartialWrapper.js
[edit]
[-] reorder.js
[edit]
[-] createBaseEach.js
[edit]
[-] baseAt.js
[edit]
[-] getLength.js
[edit]
[-] createPartial.js
[edit]
[-] createForIn.js
[edit]
[-] createFind.js
[edit]
[-] setData.js
[edit]
[-] getData.js
[edit]
[-] createSortedIndex.js
[edit]
[-] lazyValue.js
[edit]
[-] baseSlice.js
[edit]
[-] baseIsEqual.js
[edit]
[-] baseFind.js
[edit]
[-] equalArrays.js
[edit]
[-] baseForOwn.js
[edit]
[-] pickByArray.js
[edit]
[-] isKey.js
[edit]
[-] baseProperty.js
[edit]
[-] initCloneObject.js
[edit]