changed error messages to be clear on return reason