Check return code from validator rather than grep

one more time with feeling