Bump to v3.1.0.

This commit is contained in:
jdalton
2015-02-03 22:31:07 -08:00
parent bbec03c4d5
commit 9e749daefa
21 changed files with 127 additions and 66 deletions

View File

@@ -26,7 +26,7 @@ function baseCallback(func, thisArg, argCount) {
}
// Handle "_.property" and "_.matches" style callback shorthands.
return type == 'object'
? baseMatches(func, !argCount)
? baseMatches(func)
: baseProperty(func + '');
}

View File

@@ -1,5 +1,4 @@
var baseClone = require('./baseClone'),
baseIsMatch = require('./baseIsMatch'),
var baseIsMatch = require('./baseIsMatch'),
isStrictComparable = require('./isStrictComparable'),
keys = require('../object/keys');
@@ -15,10 +14,9 @@ var hasOwnProperty = objectProto.hasOwnProperty;
*
* @private
* @param {Object} source The object of property values to match.
* @param {boolean} [isCloned] Specify cloning the source object.
* @returns {Function} Returns the new function.
*/
function baseMatches(source, isCloned) {
function baseMatches(source) {
var props = keys(source),
length = props.length;
@@ -32,9 +30,6 @@ function baseMatches(source, isCloned) {
};
}
}
if (isCloned) {
source = baseClone(source, true);
}
var values = Array(length),
strictCompareFlags = Array(length);

View File

@@ -1,6 +1,6 @@
/**
* Used as the maximum length of an array-like value.
* See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
* See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.max_safe_integer)
* for more details.
*/
var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;

View File

@@ -20,7 +20,7 @@ function isIterateeCall(value, index, object) {
var length = object.length,
prereq = isLength(length) && isIndex(index, length);
} else {
prereq = type == 'string' && index in value;
prereq = type == 'string' && index in object;
}
return prereq && object[index] === value;
}

View File

@@ -1,6 +1,6 @@
/**
* Used as the maximum length of an array-like value.
* See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
* See the [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.max_safe_integer)
* for more details.
*/
var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
@@ -8,6 +8,10 @@ var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
/**
* Checks if `value` is a valid array-like length.
*
* **Note:** This function is based on ES `ToLength`. See the
* [ES spec](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength)
* for more details.
*
* @private
* @param {*} value The value to check.
* @returns {boolean} Returns `true` if `value` is a valid length, else `false`.