prevent directory change