fix file does not exist bug