jquery function that clears the error when typing in the input box