fix for sleep