We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 584b7a7 commit 1df2a39Copy full SHA for 1df2a39
shared/utils/npm.ts
@@ -42,7 +42,8 @@ export function assertValidPackageName(name: string): void {
42
if (!result.validForNewPackages && !result.validForOldPackages) {
43
const errors = [...(result.errors ?? []), ...(result.warnings ?? [])]
44
throw createError({
45
- statusCode: 400,
+ // TODO: throwing 404 rather than 400 as it's cacheable
46
+ statusCode: 404,
47
message: `Invalid package name: ${errors[0] ?? 'unknown error'}`,
48
})
49
}
0 commit comments