removed unnecessary file check