Fixed directory error check
Update to v2.5.7
Fixed directory error check