Skip to content

Commit

Permalink
fix: fix cut an paste errors in audit plugin
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Dawson <mdawson@devrus.com>
  • Loading branch information
mhdawson committed Dec 6, 2021
1 parent 655de20 commit ce9336a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/plugins/audit.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ const auditPlugin = async () => {
failure(output.get());
auditOutcome.push(
createError(
`${highRisk.length} high risk ${format} found.\n\n${formatOutputList(
`${highRisk.length} high risk ${format} found that are older than 1 month.\n\n${formatOutputList(
highRisk
)}`
)
Expand All @@ -107,11 +107,11 @@ const auditPlugin = async () => {
});

if (mediumRisk.length > 0) {
const format = highRisk.length === 1 ? 'vulnerability' : 'vulnerabilities';
const format = mediumRisk.length === 1 ? 'vulnerability' : 'vulnerabilities';
warning(output.get());
auditOutcome.push(
createWarning(
`${highRisk.length} medium risk ${format} found.\n\n${formatOutputList(
`${mediumRisk.length} medium risk ${format} found that are older than 4 months.\n\n${formatOutputList(
mediumRisk
)}`
)
Expand All @@ -122,11 +122,11 @@ const auditPlugin = async () => {
const lowRisk = auditResult.filter((v) => v.severity === 'low');

if (lowRisk.length >= 10) {
const format = highRisk.length === 1 ? 'vulnerability' : 'vulnerabilities';
const format = lowRisk.length === 1 ? 'vulnerability' : 'vulnerabilities';
warning(output.get());
auditOutcome.push(
createWarning(
`${highRisk.length} low risk ${format} found.\n\n${formatOutputList(
`${lowRisk.length} low risk ${format} found.\n\n${formatOutputList(
lowRisk
)}`
)
Expand Down

0 comments on commit ce9336a

Please sign in to comment.