Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

fix: handle undefined duration value in LogsDateFilter component

Piyush Guptaba49e4948826
diff --git a/frontend/src/pages/organization/AuditLogsPage/components/LogsDateFilter.tsx b/frontend/src/pages/organization/AuditLogsPage/components/LogsDateFilter.tsx
index d791b64cf8..b9f9a1cd6b 100644
--- a/frontend/src/pages/organization/AuditLogsPage/components/LogsDateFilter.tsx
+++ b/frontend/src/pages/organization/AuditLogsPage/components/LogsDateFilter.tsx
@@ -211,7 +211,9 @@ export const LogsDateFilter = ({ setFilter, filter, timezone, setTimezone }: Pro
type="number"
value={duration}
onChange={(val) => {
- const durationVal = val.target.value;
+ const durationVal = val.target.value
+ ? Number(val.target.value)
+ : undefined;
field.onChange(`${durationVal}${unitOfTime}`);
}}
max={60}