From 1866285d734c3c6c53ec2c1dc3b5429eb0cc8296 Mon Sep 17 00:00:00 2001 From: "S m, Aruna" Date: Thu, 8 Jun 2023 18:00:44 -0500 Subject: [PATCH] Do not check if current time is after requested time The days diff count is sufficient to know if the issue needs to be triggered. Signed-off-by: S m, Aruna --- cmd/main.go | 9 --------- 1 file changed, 9 deletions(-) diff --git a/cmd/main.go b/cmd/main.go index 14be7b5..ed02280 100644 --- a/cmd/main.go +++ b/cmd/main.go @@ -57,15 +57,6 @@ func main() { numberOfDays := int(differenceTime.Hours() / 24) log.Printf("current: %v requested: %v", currentTime, requestedTime) - - // do not proceed if the current time is way past the schedule - // reminder - if currentTime.After(requestedTime) { - // nothing to do, continue looking for - // more schedules - continue - } - log.Printf("difference: %v configured: %v", numberOfDays, config.BufferWindowDays) // found a case where action is needed