Fix sleep time method