Comparing version 1.0.6 to 1.0.7
@@ -32,1 +32,24 @@ /*! | ||
}; | ||
/** | ||
* Get value from object using string | ||
* @param {String} key string representing path | ||
* @param {Object} obj Object to travel | ||
* @return {Object} value | ||
*/ | ||
utils.getValue = function getValue(key, obj) { | ||
var nodes = key.split('.'), | ||
key = obj; | ||
do { | ||
var node = nodes.shift(); | ||
if (key && key.hasOwnProperty(node)) { | ||
key = key[node]; | ||
continue; | ||
} | ||
(key = undefined) && delete key; | ||
(nodes = null) && delete nodes; | ||
} while (nodes && nodes.length > 0); | ||
return key; | ||
}; |
{ | ||
"name": "clout-js", | ||
"version": "1.0.6", | ||
"version": "1.0.7", | ||
"description": "Clean, simplistic, enterprise grade full-stack NodeJS framework", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
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
786423
4028