Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/lib/audit.js')
-rw-r--r--deps/npm/lib/audit.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/deps/npm/lib/audit.js b/deps/npm/lib/audit.js
index 2cabef9d27d..37b54d6eca1 100644
--- a/deps/npm/lib/audit.js
+++ b/deps/npm/lib/audit.js
@@ -39,7 +39,7 @@ module.exports = auditCmd
const usage = require('./utils/usage')
auditCmd.usage = usage(
'audit',
- '\nnpm audit [--json]' +
+ '\nnpm audit [--json] [--production]' +
'\nnpm audit fix ' +
'[--force|--package-lock-only|--dry-run|--production|--only=(dev|prod)]'
)
@@ -175,7 +175,7 @@ function auditCmd (args, cb) {
const requires = Object.assign(
{},
(pkgJson && pkgJson.dependencies) || {},
- (pkgJson && pkgJson.devDependencies) || {}
+ (!opts.production && pkgJson && pkgJson.devDependencies) || {}
)
return lockVerify(npm.prefix).then((result) => {
if (result.status) return audit.generate(sw, requires)