fix history of directory error