fix remove dir and fix remove component files