fix(frontend): align zod v4 typings and defaults
Some checks failed
CICD / Build CICD Image Failure Postmortem (push) Has been cancelled
CICD / Build and Push CICD Images (push) Has been cancelled
CICD / Source Checks (push) Has been cancelled
CICD / Dependency Audits (Informational) (push) Has been cancelled
CICD / CICD Tests Complete (push) Has been cancelled
CICD / Build Release Images (push) Has been cancelled
CICD / Build Tester Images (push) Has been cancelled
CICD / Production Images Complete (push) Has been cancelled
CICD / Production Image Failures Postmortem (push) Has been cancelled
CICD / Source Lanes Failure Postmortem (push) Has been cancelled
CICD / Runtime Black-Box Integration Tests (push) Has been cancelled
CICD / Integration Tests Failure Postmortem (push) Has been cancelled
CICD / End-to-End Tests (push) Has been cancelled
CICD / E2E Tests Failure Postmortem (push) Has been cancelled
CICD / Promote Staging Images To Release (push) Has been cancelled

This commit is contained in:
copilotcoder
2026-07-22 10:59:55 -04:00
parent ff53dec2c2
commit 87f977280c
2 changed files with 2 additions and 5 deletions

View File

@@ -46,10 +46,7 @@ function enhancedParse<T>(this: z.ZodType<T>, data: unknown): T {
* @param data - The data to validate against the schema
* @returns Safe parse result with success flag and data or error
*/
function enhancedSafeParse<T>(
this: z.ZodType<T>,
data: unknown
): z.SafeParseReturnType<unknown, T> {
function enhancedSafeParse<T>(this: z.ZodType<T>, data: unknown) {
const result = originalSafeParse.call(this, data);
validationCount++;

View File

@@ -22,7 +22,7 @@ export const UserSchema = z.object({
theme: z.enum(['light', 'dark']).default('light'),
notifications: z.boolean().default(true),
})
.default({}),
.default({ theme: 'light', notifications: true }),
});
// Inferred types (no manual type definitions needed)