adding var for time to wait