From 3d27ce2388c541cd0e819e4dcd2351d948a0011c Mon Sep 17 00:00:00 2001 From: Mihovil Ilakovac Date: Wed, 30 Oct 2024 19:42:54 +0100 Subject: [PATCH] Update env validation fn type usage --- waspc/examples/todoApp/src/env.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/waspc/examples/todoApp/src/env.ts b/waspc/examples/todoApp/src/env.ts index bd74293604..1a7c4cb6e3 100644 --- a/waspc/examples/todoApp/src/env.ts +++ b/waspc/examples/todoApp/src/env.ts @@ -1,14 +1,14 @@ import * as z from 'zod' import type { EnvValidationFn } from 'wasp/env' -export const serverEnvValidationFn: EnvValidationFn = () => +export const serverEnvValidationFn = (() => z.object({ MY_ENV_VAR: z.string({ required_error: 'MY_ENV_VAR is required.', }), - }) + })) satisfies EnvValidationFn -export const clientEnvValidationFn: EnvValidationFn = () => +export const clientEnvValidationFn = (() => z.object({ REACT_APP_NAME: z.string().default('TODO App'), - }) + })) satisfies EnvValidationFn