removed thread sleep