Properly manage directory name change