Added CheckIfHasFiles