Bump to v4.0.0.

This commit is contained in:
John-David Dalton
2016-02-26 01:06:04 -08:00
parent 51e917b094
commit d35a9c40be
1337 changed files with 70148 additions and 17945 deletions

View File

@@ -1,15 +1,15 @@
/**
* lodash 3.1.0 (Custom Build) <https://lodash.com/>
* Build: `lodash modern modularize exports="npm" -o ./`
* Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
* lodash 4.0.0 (Custom Build) <https://lodash.com/>
* Build: `lodash modularize exports="npm" -o ./`
* Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/>
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
* Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
* Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
* Available under MIT license <https://lodash.com/license>
*/
var sample = require('lodash.sample');
var sampleSize = require('lodash.samplesize');
/** Used as references for `-Infinity` and `Infinity`. */
var POSITIVE_INFINITY = Number.POSITIVE_INFINITY;
/** Used as references for the maximum length and index of an array. */
var MAX_ARRAY_LENGTH = 4294967295;
/**
* Creates an array of shuffled values, using a version of the
@@ -17,8 +17,9 @@ var POSITIVE_INFINITY = Number.POSITIVE_INFINITY;
*
* @static
* @memberOf _
* @since 0.1.0
* @category Collection
* @param {Array|Object|string} collection The collection to shuffle.
* @param {Array|Object} collection The collection to shuffle.
* @returns {Array} Returns the new shuffled array.
* @example
*
@@ -26,7 +27,7 @@ var POSITIVE_INFINITY = Number.POSITIVE_INFINITY;
* // => [4, 1, 3, 2]
*/
function shuffle(collection) {
return sample(collection, POSITIVE_INFINITY);
return sampleSize(collection, MAX_ARRAY_LENGTH);
}
module.exports = shuffle;