From c4e5d7786e4b9df4b9c34c7d81bb9f2e23cd90fd Mon Sep 17 00:00:00 2001 From: Nicolas Mowen Date: Sun, 10 Mar 2024 13:49:05 -0600 Subject: [PATCH] Fix -1 text --- web/src/views/events/EventView.tsx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/web/src/views/events/EventView.tsx b/web/src/views/events/EventView.tsx index 59912af2a..3ac6c1330 100644 --- a/web/src/views/events/EventView.tsx +++ b/web/src/views/events/EventView.tsx @@ -85,7 +85,7 @@ export default function EventView({ } if (!summary) { - return { alert: 0, detection: 0, significant_motion: 0 }; + return { alert: -1, detection: -1, significant_motion: -1 }; } if (filter?.showReviewed == 1) { @@ -206,7 +206,9 @@ export default function EventView({ aria-label="Select alerts" > -
Alerts ∙ {reviewCounts.alert}
+
+ Alerts{` ∙ ${reviewCounts.alert > -1 ? reviewCounts.alert : ""}`} +
- Detections ∙ {reviewCounts.detection} + Detections + {` ∙ ${reviewCounts.detection > -1 ? reviewCounts.detection : ""}`}