read-package-json
Advanced tools
Comparing version 1.1.5 to 1.1.6
{ | ||
"name": "read-package-json", | ||
"version": "1.1.5", | ||
"version": "1.1.6", | ||
"author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)", | ||
@@ -5,0 +5,0 @@ "description": "The thing npm uses to read package.json files with semantics and defaults and validation", |
@@ -114,2 +114,3 @@ // vim: set softtabstop=16 shiftwidth=16: | ||
} | ||
if (!log) log = function () {}; | ||
cb = arguments[i] | ||
@@ -138,2 +139,5 @@ var set = readJson.extraSet | ||
s = this[key] | ||
// This is never allowed, and only causes problems | ||
if (typeof s !== 'string') | ||
return delete this[key] | ||
var spre = /^(\.[\/\\])?node_modules[\/\\].bin[\\\/]/ | ||
@@ -337,5 +341,6 @@ if (s.match(spre)) | ||
function makePackageId (data) { | ||
return cleanString(data.name) + "@" + cleanString(data.version) | ||
var name = cleanString(data.name) | ||
var ver = cleanString(data.version) | ||
return name + "@" + ver | ||
} | ||
function cleanString(str) { | ||
@@ -342,0 +347,0 @@ return (!str || typeof(str) !== "string") ? "" : str.trim() |
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
26506
511