From d41421a9b5597ebfd8acd2936acdd77024f1183b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Po=C5=9Bpiech?= Date: Tue, 18 Jun 2024 10:37:25 +0200 Subject: [PATCH] removed initial value from enum type --- packages/uniforms-bridge-zod/src/ZodBridge.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/packages/uniforms-bridge-zod/src/ZodBridge.ts b/packages/uniforms-bridge-zod/src/ZodBridge.ts index eb0f45072..ec3da0af0 100644 --- a/packages/uniforms-bridge-zod/src/ZodBridge.ts +++ b/packages/uniforms-bridge-zod/src/ZodBridge.ts @@ -152,10 +152,6 @@ export default class ZodBridge extends Bridge { return field._def.defaultValue(); } - if (field instanceof ZodEnum) { - return field.options[0]; - } - if (field instanceof ZodNativeEnum) { const values = Object.values(field.enum as Record); return values.find(isNativeEnumValue) ?? values[0];