From 70d9533b1316248ba76fa6bcee5438aec3d98caa Mon Sep 17 00:00:00 2001 From: Pontus Dreij Date: Wed, 18 Dec 2024 16:48:10 +0100 Subject: [PATCH 1/2] fix: schema error included --- server/routers/hotels/schemas/restaurants.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/routers/hotels/schemas/restaurants.ts b/server/routers/hotels/schemas/restaurants.ts index 549c10f81..b58b4d7a4 100644 --- a/server/routers/hotels/schemas/restaurants.ts +++ b/server/routers/hotels/schemas/restaurants.ts @@ -58,8 +58,8 @@ export const restaurantSchema = z images: z.array(imageSchema), texts: z.object({ descriptions: z.object({ - short: z.string(), - medium: z.string(), + short: z.string().optional(), + medium: z.string().optional(), }), }), bookTableUrl: z.string().optional(), From 54086c40fc6d9ebf9be09e97c0f6f02f5839da23 Mon Sep 17 00:00:00 2001 From: Pontus Dreij Date: Thu, 19 Dec 2024 15:33:23 +0100 Subject: [PATCH 2/2] fix: Changed to default --- server/routers/hotels/schemas/restaurants.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/routers/hotels/schemas/restaurants.ts b/server/routers/hotels/schemas/restaurants.ts index b58b4d7a4..4fd8e295a 100644 --- a/server/routers/hotels/schemas/restaurants.ts +++ b/server/routers/hotels/schemas/restaurants.ts @@ -58,8 +58,8 @@ export const restaurantSchema = z images: z.array(imageSchema), texts: z.object({ descriptions: z.object({ - short: z.string().optional(), - medium: z.string().optional(), + short: z.string().default(""), + medium: z.string().default(""), }), }), bookTableUrl: z.string().optional(),