lodash._basematches
Advanced tools
Comparing version 3.1.0 to 3.1.1
53
index.js
/** | ||
* lodash 3.1.0 (Custom Build) <https://lodash.com/> | ||
* lodash 3.1.1 (Custom Build) <https://lodash.com/> | ||
* Build: `lodash modern modularize exports="npm" -o ./` | ||
@@ -9,3 +9,3 @@ * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> | ||
*/ | ||
var baseIsEqual = require('lodash._baseisequal'), | ||
var baseIsMatch = require('lodash._baseismatch'), | ||
keys = require('lodash.keys'); | ||
@@ -20,51 +20,2 @@ | ||
/** | ||
* The base implementation of `_.isMatch` without support for callback | ||
* shorthands or `this` binding. | ||
* | ||
* @private | ||
* @param {Object} source The object to inspect. | ||
* @param {Array} props The source property names to match. | ||
* @param {Array} values The source values to match. | ||
* @param {Array} strictCompareFlags Strict comparison flags for source values. | ||
* @param {Function} [customizer] The function to customize comparing objects. | ||
* @returns {boolean} Returns `true` if `object` is a match, else `false`. | ||
*/ | ||
function baseIsMatch(object, props, values, strictCompareFlags, customizer) { | ||
var length = props.length; | ||
if (object == null) { | ||
return !length; | ||
} | ||
var index = -1, | ||
noCustomizer = !customizer; | ||
while (++index < length) { | ||
if ((noCustomizer && strictCompareFlags[index]) | ||
? values[index] !== object[props[index]] | ||
: !hasOwnProperty.call(object, props[index]) | ||
) { | ||
return false; | ||
} | ||
} | ||
index = -1; | ||
while (++index < length) { | ||
var key = props[index]; | ||
if (noCustomizer && strictCompareFlags[index]) { | ||
var result = hasOwnProperty.call(object, key); | ||
} else { | ||
var objValue = object[key], | ||
srcValue = values[index]; | ||
result = customizer ? customizer(objValue, srcValue, key) : undefined; | ||
if (typeof result == 'undefined') { | ||
result = baseIsEqual(srcValue, objValue, customizer, true); | ||
} | ||
} | ||
if (!result) { | ||
return false; | ||
} | ||
} | ||
return true; | ||
} | ||
/** | ||
* The base implementation of `_.matches` which supports specifying whether | ||
@@ -71,0 +22,0 @@ * `source` should be cloned. |
{ | ||
"name": "lodash._basematches", | ||
"version": "3.1.0", | ||
"version": "3.1.1", | ||
"description": "The modern build of lodash’s internal `baseMatches` as a module.", | ||
@@ -19,5 +19,5 @@ "homepage": "https://lodash.com/", | ||
"dependencies": { | ||
"lodash._baseisequal": "^3.0.0", | ||
"lodash._baseismatch": "^3.0.0", | ||
"lodash.keys": "^3.0.0" | ||
} | ||
} |
@@ -1,2 +0,2 @@ | ||
# lodash._basematches v3.1.0 | ||
# lodash._basematches v3.1.1 | ||
@@ -20,2 +20,2 @@ The [modern build](https://github.com/lodash/lodash/wiki/Build-Differences) of [lodash’s](https://lodash.com/) internal `baseMatches` exported as a [Node.js](http://nodejs.org/)/[io.js](https://iojs.org/) module. | ||
See the [package source](https://github.com/lodash/lodash/blob/3.1.0-npm-packages/lodash._basematches) for more details. | ||
See the [package source](https://github.com/lodash/lodash/blob/3.1.1-npm-packages/lodash._basematches) for more details. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5481
85
+ Addedlodash._baseismatch@^3.0.0
+ Addedlodash._baseismatch@3.1.3(transitive)
- Removedlodash._baseisequal@^3.0.0