feat: add input length validation
This commit is contained in:
@@ -27,7 +27,7 @@ export const cardRouter = createTRPCRouter({
|
|||||||
})
|
})
|
||||||
.input(
|
.input(
|
||||||
z.object({
|
z.object({
|
||||||
title: z.string().min(1),
|
title: z.string().min(1).max(2000),
|
||||||
description: z.string().max(10000),
|
description: z.string().max(10000),
|
||||||
listPublicId: z.string().min(12),
|
listPublicId: z.string().min(12),
|
||||||
labelPublicIds: z.array(z.string().min(12)),
|
labelPublicIds: z.array(z.string().min(12)),
|
||||||
@@ -760,7 +760,7 @@ export const cardRouter = createTRPCRouter({
|
|||||||
.input(
|
.input(
|
||||||
z.object({
|
z.object({
|
||||||
cardPublicId: z.string().min(12),
|
cardPublicId: z.string().min(12),
|
||||||
title: z.string().min(1).optional(),
|
title: z.string().min(1).max(2000).optional(),
|
||||||
description: z.string().optional(),
|
description: z.string().optional(),
|
||||||
index: z.number().optional(),
|
index: z.number().optional(),
|
||||||
listPublicId: z.string().min(12).optional(),
|
listPublicId: z.string().min(12).optional(),
|
||||||
|
|||||||
Reference in New Issue
Block a user