Change how to detect an error message.