Added setTimeout function.