removing bad directories