Skip to content

Commit

Permalink
Removes warnings from package manifest
Browse files Browse the repository at this point in the history
  • Loading branch information
ruyadorno authored and isaacs committed Oct 7, 2019
1 parent 62f2ca6 commit 3547d99
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/install/validate-tree.js
Expand Up @@ -39,8 +39,9 @@ function checkErrors (mod, idealTree, next) {

function checkWarnings (mod, idealTree, next) {
const warnings = mod.package.warnings
if (warnings && (mod.parent || path.resolve(npm.globalDir, '..'))) {
if (warnings && (mod.parent || path.resolve(npm.globalDir, '..') !== mod.path)) {
warnings.forEach(warn => idealTree.warnings.push(warn))
delete mod.package.warnings
}
next()
}
Expand Down

0 comments on commit 3547d99

Please sign in to comment.