Skip to content

Commit 077b854

Browse files
fix(components): drop whitespace-only and empty entries in PUT /catalogue (#379)
Co-authored-by: David McKay <david@copilotkit.ai>
1 parent d0cbe81 commit 077b854

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎server/src/components/routes.ts‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,11 +95,13 @@ export function createComponentRoutes(
9595
>;
9696
if (
9797
typeof name !== "string" ||
98-
!name ||
98+
!name.trim() ||
9999
typeof title !== "string" ||
100+
!title.trim() ||
100101
typeof kind !== "string" ||
102+
!kind.trim() ||
101103
typeof description !== "string" ||
102-
!description
104+
!description.trim()
103105
) {
104106
return [];
105107
}

0 commit comments

Comments
 (0)