From 75e03cd7cf83ab352def8a3448c6c05af8f5eeec Mon Sep 17 00:00:00 2001 From: sanny-io Date: Mon, 2 Feb 2026 07:49:01 +0000 Subject: [PATCH 1/2] fix: swap schema numbers for positive integers --- packages/cache/src/schemas.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/cache/src/schemas.ts b/packages/cache/src/schemas.ts index 7f77c36..351f909 100644 --- a/packages/cache/src/schemas.ts +++ b/packages/cache/src/schemas.ts @@ -1,8 +1,8 @@ import z from 'zod' export const cacheOptionsSchema = z.strictObject({ - ttl: z.number().min(1).optional(), - swr: z.number().min(1).optional(), + ttl: z.int().positive().min(1).optional(), + swr: z.int().positive().min(1).optional(), tags: z.string().array().optional(), }) From 01dd533ddf201dee47c898eeb2b418330aaf3361 Mon Sep 17 00:00:00 2001 From: sanny-io Date: Mon, 2 Feb 2026 07:56:03 +0000 Subject: [PATCH 2/2] Remove redundant `min` call. --- packages/cache/src/schemas.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/cache/src/schemas.ts b/packages/cache/src/schemas.ts index 351f909..261eb9f 100644 --- a/packages/cache/src/schemas.ts +++ b/packages/cache/src/schemas.ts @@ -1,8 +1,8 @@ import z from 'zod' export const cacheOptionsSchema = z.strictObject({ - ttl: z.int().positive().min(1).optional(), - swr: z.int().positive().min(1).optional(), + ttl: z.int().positive().optional(), + swr: z.int().positive().optional(), tags: z.string().array().optional(), })