From 8572065ef7e4cc6681b3c188b1ef59a47c1f9c8b Mon Sep 17 00:00:00 2001 From: Br0wnHammer Date: Wed, 3 Jun 2026 20:16:10 +0530 Subject: [PATCH] fix(client): validate hardware alert thresholds on the wizard's second step --- client/src/Validation/monitor.ts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/client/src/Validation/monitor.ts b/client/src/Validation/monitor.ts index 5d7ed93af..80d0d77c4 100644 --- a/client/src/Validation/monitor.ts +++ b/client/src/Validation/monitor.ts @@ -128,19 +128,23 @@ const hardwareSchema = baseSchema.extend({ cpuAlertThreshold: z .number() .min(0, "CPU threshold must be at least 0") - .max(100, "CPU threshold must be at most 100"), + .max(100, "CPU threshold must be at most 100") + .register(monitorStepRegistry, { step: 1 }), memoryAlertThreshold: z .number() .min(0, "Memory threshold must be at least 0") - .max(100, "Memory threshold must be at most 100"), + .max(100, "Memory threshold must be at most 100") + .register(monitorStepRegistry, { step: 1 }), diskAlertThreshold: z .number() .min(0, "Disk threshold must be at least 0") - .max(100, "Disk threshold must be at most 100"), + .max(100, "Disk threshold must be at most 100") + .register(monitorStepRegistry, { step: 1 }), tempAlertThreshold: z .number() .min(0, "Temperature threshold must be at least 0") - .max(150, "Temperature threshold must be at most 150"), + .max(150, "Temperature threshold must be at most 150") + .register(monitorStepRegistry, { step: 1 }), selectedDisks: z.array(z.string()), });