Bump to v3.10.0.

This commit is contained in:
jdalton
2015-06-14 22:21:45 -07:00
parent 10d5566cf2
commit b97a9a3da0
121 changed files with 1412 additions and 1168 deletions

View File

@@ -1,11 +1,10 @@
var baseSlice = require('../internal/baseSlice'),
isIterateeCall = require('../internal/isIterateeCall');
/** Native method references. */
var ceil = Math.ceil;
/* Native method references for those with the same name as other `lodash` methods. */
var nativeMax = Math.max;
var nativeCeil = Math.ceil,
nativeFloor = Math.floor,
nativeMax = Math.max;
/**
* Creates an array of elements split into groups the length of `size`.
@@ -31,12 +30,12 @@ function chunk(array, size, guard) {
if (guard ? isIterateeCall(array, size, guard) : size == null) {
size = 1;
} else {
size = nativeMax(+size || 1, 1);
size = nativeMax(nativeFloor(size) || 1, 1);
}
var index = 0,
length = array ? array.length : 0,
resIndex = -1,
result = Array(ceil(length / size));
result = Array(nativeCeil(length / size));
while (index < length) {
result[++resIndex] = baseSlice(array, index, (index += size));