Modify audit period ending to consider exact midnight

Audit period ending should also take into account the value at exact midnight. This makes the script account for periodic exists events that are stored exactly at midnight.