Fixed another file checking bug