Skip to content

Commit f64c011

Browse files
committed
fix: timeout and limitRows
1 parent 470d285 commit f64c011

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/utils/query.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -366,11 +366,11 @@ export const querySettingsRestoreSchema = z
366366
.object({
367367
timeout: z.preprocess(
368368
(val) => (val === '' ? undefined : val),
369-
z.coerce.number().positive().catch(DEFAULT_QUERY_SETTINGS.timeout),
369+
z.coerce.number().positive().optional().catch(DEFAULT_QUERY_SETTINGS.timeout),
370370
),
371371
limitRows: z.preprocess(
372372
(val) => (val === '' ? undefined : val),
373-
z.coerce.number().gt(0).lte(10_000).catch(DEFAULT_QUERY_SETTINGS.limitRows),
373+
z.coerce.number().gt(0).lte(10_000).optional().catch(DEFAULT_QUERY_SETTINGS.limitRows),
374374
),
375375
queryMode: queryModeSchema.catch(DEFAULT_QUERY_SETTINGS.queryMode),
376376
transactionMode: transactionModeSchema.catch(DEFAULT_QUERY_SETTINGS.transactionMode),

0 commit comments

Comments
 (0)