fix the wrong sleep in a async method