Skip to content

Commit

Permalink
Do not check if current time is after requested time
Browse files Browse the repository at this point in the history
The days diff count is sufficient to know if the issue
needs to be triggered.

Signed-off-by: S m, Aruna <[email protected]>
  • Loading branch information
arsulegai committed Jun 8, 2023
1 parent 694dd6b commit 1866285
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 1866285

Please sign in to comment.