dot-object
Advanced tools
Comparing version 0.5.0 to 0.6.0
22
index.js
@@ -174,2 +174,23 @@ 'use strict'; | ||
/** | ||
* | ||
* Copy a property from one object to another object. | ||
* | ||
* If the source path does not exist (undefined) | ||
* the property on the other object will not be set. | ||
* | ||
* @param {String} source | ||
* @param {String} target | ||
* @param {Object} obj1 | ||
* @param {Object} obj2 | ||
* @param {Boolean} merge | ||
*/ | ||
DotObject.prototype.copy = function(source, target, obj1, obj2, merge) { | ||
this.set(target, this.pick(source, obj1, false), obj2, merge); | ||
return obj2; | ||
}; | ||
function isObject(val) { | ||
@@ -192,3 +213,2 @@ return Object.prototype.toString.call(val) === '[object Object]'; | ||
var keys; | ||
var isArray; | ||
@@ -195,0 +215,0 @@ // Do not operate if the value is undefined. |
{ | ||
"name": "dot-object", | ||
"description": "dot-object makes it possible to transform and read (JSON) objects using dot notation.", | ||
"version": "0.5.0", | ||
"version": "0.6.0", | ||
"author": { | ||
@@ -37,3 +37,6 @@ "name": "Rob Halff", | ||
"dot" | ||
] | ||
], | ||
"dependencies": { | ||
"commander": "^2.5.0" | ||
} | ||
} |
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
20874
11
1
547
+ Addedcommander@^2.5.0
+ Addedcommander@2.20.3(transitive)