lodash.defaults
Advanced tools
Comparing version 3.0.0 to 3.1.0
16
index.js
/** | ||
* lodash 3.0.0 (Custom Build) <https://lodash.com/> | ||
* 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/> | ||
* Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE> | ||
* Based on Underscore.js 1.8.2 <http://underscorejs.org/LICENSE> | ||
* Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors | ||
* Available under MIT license <https://lodash.com/license> | ||
*/ | ||
var arrayCopy = require('lodash._arraycopy'), | ||
assign = require('lodash.assign'); | ||
var assign = require('lodash.assign'), | ||
restParam = require('lodash.restparam'); | ||
@@ -27,3 +27,3 @@ /** | ||
* object for all destination properties that resolve to `undefined`. Once a | ||
* property is set, additional defaults of the same property are ignored. | ||
* property is set, additional values of the same property are ignored. | ||
* | ||
@@ -41,11 +41,11 @@ * @static | ||
*/ | ||
function defaults(object) { | ||
var defaults = restParam(function(args) { | ||
var object = args[0]; | ||
if (object == null) { | ||
return object; | ||
} | ||
var args = arrayCopy(arguments); | ||
args.push(assignDefaults); | ||
return assign.apply(undefined, args); | ||
} | ||
}); | ||
module.exports = defaults; |
Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> | ||
Based on Underscore.js 1.7.0, copyright 2009-2015 Jeremy Ashkenas, | ||
Based on Underscore.js, copyright 2009-2015 Jeremy Ashkenas, | ||
DocumentCloud and Investigative Reporters & Editors <http://underscorejs.org/> | ||
@@ -4,0 +4,0 @@ |
{ | ||
"name": "lodash.defaults", | ||
"version": "3.0.0", | ||
"version": "3.1.0", | ||
"description": "The modern build of lodash’s `_.defaults` as a module.", | ||
@@ -20,5 +20,5 @@ "homepage": "https://lodash.com/", | ||
"dependencies": { | ||
"lodash._arraycopy": "^3.0.0", | ||
"lodash.assign": "^3.0.0" | ||
"lodash.assign": "^3.0.0", | ||
"lodash.restparam": "^3.0.0" | ||
} | ||
} |
@@ -1,2 +0,2 @@ | ||
# lodash.defaults v3.0.0 | ||
# lodash.defaults v3.1.0 | ||
@@ -20,2 +20,2 @@ The [modern build](https://github.com/lodash/lodash/wiki/Build-Differences) of [lodash’s](https://lodash.com/) `_.defaults` exported as a [Node.js](http://nodejs.org/)/[io.js](https://iojs.org/) module. | ||
See the [documentation](https://lodash.com/docs#defaults) or [package source](https://github.com/lodash/lodash/blob/3.0.0-npm-packages/lodash.defaults) for more details. | ||
See the [documentation](https://lodash.com/docs#defaults) or [package source](https://github.com/lodash/lodash/blob/3.1.0-npm-packages/lodash.defaults) 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
4452
+ Addedlodash.restparam@^3.0.0
- Removedlodash._arraycopy@^3.0.0
- Removedlodash._arraycopy@3.0.0(transitive)