Skip to content

Commit d48264a

Browse files
committed
fix(projects): trim the requested organization id before validating it
1 parent 325ecea commit d48264a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎apps/sim/lib/projects/create-input.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { z } from 'zod'
22
import { organizationIdSchema } from '@/lib/api/contracts/primitives'
33

44
export const createProjectInputSchema = z.object({
5-
organizationId: organizationIdSchema.nullable(),
5+
organizationId: z.string().trim().pipe(organizationIdSchema).nullable(),
66
name: z.string().trim().min(1).max(100),
77
initialEnvironment: z.object({ name: z.string().trim().min(1).max(100) }),
88
})

0 commit comments

Comments
 (0)