Skip to content

Commit 18c0ed5

Browse files
committed
fixes purl in cve-detail
1 parent 517600d commit 18c0ed5

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/components/vulnerability-database/cve-detail.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,8 @@ export default function CVEDetailComponent({ cveId }: { cveId?: string }) {
273273
<div className="border-t border-gray-700 px-6 pb-6 pt-4">
274274
<div className="flex flex-col gap-2">
275275
{data.affectedComponents.filter((ac) => ac.version != null && ac.version !== 'null').map((ac) => {
276-
const purl = `pkg:${ac.ecosystem}/${ac.name}@${ac.version}`
276+
const version = ac.version?.replace(/^v/, '')
277+
const purl = `pkg:${ac.ecosystem}/${ac.name}@${version}`
277278
return (
278279
<Link
279280
key={ac.id}

0 commit comments

Comments
 (0)