add a line for input error checking