minor bug fixes for timer