Fixed some unwanted behavior when the timer finishes.