diff --git a/helpdesk/lib.py b/helpdesk/lib.py index bd8c4a42..96bb430f 100644 --- a/helpdesk/lib.py +++ b/helpdesk/lib.py @@ -220,7 +220,7 @@ def daily_time_spent_calculation(earliest, latest, open_hours): latest_f = latest.hour + latest.minute / 60 + latest.second / (60 * 60) + latest.microsecond / (60 * 60 * 999999) # if latest time is midnight and close hour is midnight, add a second to the time spent - if latest_f >= 24 and end == MIDNIGHT: + if latest_f >= MIDNIGHT and end == MIDNIGHT: time_spent_seconds += 1 if earliest_f < start: