added file check to the read command