Updated code for timers.