Skip to content

Commit

Permalink
fix: display the actual name of the missing file during failed remedi…
Browse files Browse the repository at this point in the history
…ation patch
  • Loading branch information
Konstantin Yegupov committed May 9, 2019
1 parent c6527e8 commit 25acf41
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion src/lib/protect/apply-patch.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ function trimUpToFirstSlash(fileName) {

function patchError(error, dir, vuln, patchUrl) {
if (error && error.code === 'ENOENT') {
error.message = 'Failed to patch: the target could not be found.';
error.message = 'Failed to patch: the target could not be found (' + error.message + ').';
return Promise.reject(error);
}

Expand Down
1 change: 0 additions & 1 deletion src/lib/snyk-test/nodejs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ async function runTest(packageManager: string, root: string, options): Promise<o
}
}


analytics.add('vulns-pre-policy', res.vulnerabilities.length);

res.filesystemPolicy = !!payloadPolicy;
Expand Down

0 comments on commit 25acf41

Please sign in to comment.