diff --git a/server/constants/env.ts b/server/constants/env.ts index 6449f18..63ff568 100644 --- a/server/constants/env.ts +++ b/server/constants/env.ts @@ -1,10 +1,14 @@ import { z } from 'zod'; export const clientEnvSchema = z.object({ - API_URL: z.string(), + API_URL: z.string().regex(/^(.*[^/])$/g, { + message: 'API 주소는 슬래시(/)로 끝나지 않아야 합니다.', + }), }); export const serverEnvSchema = z.object({ AUTH_COOKIE_SESSION_SECRET: z.string(), - API_URL: z.string(), + API_URL: z.string().regex(/^(.*[^/])$/g, { + message: 'API 주소는 슬래시(/)로 끝나지 않아야 합니다.', + }), });