Skip to content

Commit

Permalink
fix: upgrade marked dependency (#411)
Browse files Browse the repository at this point in the history
  • Loading branch information
cat2608 authored Dec 13, 2023
1 parent fb453ca commit a1c763b
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 21 deletions.
41 changes: 24 additions & 17 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@
"@types/glob": "^8.1.0",
"@types/he": "^1.2.3",
"@types/lodash": "^4.14.161",
"@types/marked": "^3.0.0",
"@types/marked": "^6.0.0",
"@types/mocha": "^8.0.3",
"@types/needle": "^2.5.2",
"@types/node": "^14.6.2",
Expand Down Expand Up @@ -447,7 +447,7 @@
"http-proxy-agent": "^5.0.0",
"https-proxy-agent": "^5.0.0",
"lodash": "^4.17.21",
"marked": "^4.0.16",
"marked": "^11.1.0",
"open": "^7.4.2",
"rxjs": "^7.8.1",
"string-argv": "^0.3.1",
Expand Down
4 changes: 2 additions & 2 deletions src/snyk/snykOss/providers/ossIssueCommandHelper.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import marked from 'marked';
import { marked } from 'marked';
import { Issue, OssIssueData } from '../../common/languageServer/types';
import { OssIssueCommandArg } from '../interfaces';

Expand All @@ -12,7 +12,7 @@ export function getOssIssueCommandArg(

try {
// TODO: marked.parse does not sanitize the HTML. See: https://marked.js.org/#usage
overviewHtml = marked.parse(vuln.additionalData.description);
overviewHtml = marked.parse(vuln.additionalData.description) as string;
} catch (error) {
overviewHtml = '<p>There was a problem rendering the vulnerability overview</p>';
}
Expand Down

0 comments on commit a1c763b

Please sign in to comment.