license-checker
Advanced tools
Comparing version 0.0.4 to 0.0.5
@@ -15,5 +15,5 @@ | ||
var flatten = function(json) { | ||
var moduleInfo = {licenses: UNKNOWN} | ||
var moduleId; | ||
var moduleInfo = {licenses: UNKNOWN}, | ||
licenseData; | ||
data[json.name + '@' + json.version] = moduleInfo; | ||
@@ -33,3 +33,3 @@ | ||
var licenseData = json.license || json.licenses || undefined; | ||
licenseData = json.license || json.licenses || undefined; | ||
if (licenseData) { | ||
@@ -39,3 +39,3 @@ if (Array.isArray(licenseData) && licenseData.length > 0) { | ||
if (typeof license === 'object') { | ||
return license.type | ||
return license.type; | ||
} else if (typeof license === 'string') { | ||
@@ -52,7 +52,7 @@ return license; | ||
moduleInfo.licenses = license(json.readme) || UNKNOWN; | ||
} | ||
} | ||
if (json.dependencies) { | ||
Object.keys(json.dependencies).forEach(function(name) { | ||
var childDependency = json.dependencies[name]; | ||
var dependencyId = childDependency.name + '@' + childDependency.version; | ||
var childDependency = json.dependencies[name], | ||
dependencyId = childDependency.name + '@' + childDependency.version; | ||
if (data[dependencyId]) { // already exists | ||
@@ -59,0 +59,0 @@ return; |
@@ -1,2 +0,2 @@ | ||
module.exports = function(str){ | ||
module.exports = function(str) { | ||
if (str.indexOf('MIT') > -1) { | ||
@@ -12,2 +12,2 @@ return 'MIT*'; | ||
return null; | ||
} | ||
}; |
@@ -5,3 +5,3 @@ { | ||
"author": "Dav Glass <davglass@gmail.com>", | ||
"version": "0.0.4", | ||
"version": "0.0.5", | ||
"dependencies": { | ||
@@ -16,3 +16,4 @@ "mkdirp": "*", | ||
"jshint": "~1.1.0", | ||
"vows": "*" | ||
"vows": "*", | ||
"istanbul": "*" | ||
}, | ||
@@ -19,0 +20,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
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
10959
11
194
4