Fix cutoff time bug and add a test