removed unecessary file check