Code cleanup after directory system change