From a1e4649455c3bcb86a472d09fb4e69b061d99929 Mon Sep 17 00:00:00 2001 From: nathan Date: Tue, 3 Dec 2024 09:15:19 +1100 Subject: [PATCH] Update main.go --- main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index 1bb1a40..aa9c7bf 100644 --- a/main.go +++ b/main.go @@ -294,8 +294,8 @@ func main() { // make sure that this event is within 10 minutes either side of the corresponding host failed event if hostFound { - unreachableStartComparison := h.CreatedTime.In(location).Add(time.Duration(int64(time.Minute) * -1 * *unreachableMinutes)) - unreachableEndComparison := h.CreatedTime.In(location).Add(time.Duration(int64(time.Minute) * *unreachableMinutes)) + unreachableStartComparison := h.CreatedTime.In(location).Add(time.Duration(int64(time.Minute) * -1 * int64(*unreachableMinutes))) + unreachableEndComparison := h.CreatedTime.In(location).Add(time.Duration(int64(time.Minute) * int64(*unreachableMinutes))) if haFailedTime.Before(unreachableEndComparison) && haFailedTime.After(unreachableStartComparison) { haUnreachableEvents = append(haUnreachableEvents, h)