removing waiting loop