diff --git a/src/pages/Licenses/Licenses.tsx b/src/pages/Licenses/Licenses.tsx index a1c4b7fba53..1f1cf8ab744 100644 --- a/src/pages/Licenses/Licenses.tsx +++ b/src/pages/Licenses/Licenses.tsx @@ -29,11 +29,11 @@ function getPackageUrl(pkgName: string, purl: string): string { githubactions: `https://github.com/actions/${pkgName}`, }; - const pkgtype = Object.keys(urlMap).find((key) => + const pkgType = Object.keys(urlMap).find((key) => purl.startsWith(`pkg:${key}/`), ); - return pkgtype ? urlMap[pkgtype as PackageType] : purl; + return pkgType ? urlMap[pkgType as PackageType] : purl; } export const LicensesPage = () => {