Fix for invalid error messages.