change timer code and delete warning