properly remove dir