feat: applied coderabbit suggestions

This commit is contained in:
Muhamad Aji Wibisono 2025-06-02 21:03:50 +07:00
parent afc1100f6d
commit 42cc1b8fbe
5 changed files with 11 additions and 21 deletions

View file

@ -47,9 +47,9 @@ const discordConnectorFormSchema = z.object({
name: z.string().min(3, {
message: "Connector name must be at least 3 characters.",
}),
bot_token: z.string().min(10, {
message: "Discord Bot Token is required and must be valid.",
}),
bot_token: z.string()
.min(50, { message: "Discord Bot Token appears to be too short." })
.regex(/^[A-Za-z0-9._-]+$/, { message: "Discord Bot Token contains invalid characters." }),
});
// Define the type for the form values