checks for errors, at least