diff options
Diffstat (limited to 'SendGrid/SendGridMail/Transport/Web.cs')
-rwxr-xr-x | SendGrid/SendGridMail/Transport/Web.cs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/SendGrid/SendGridMail/Transport/Web.cs b/SendGrid/SendGridMail/Transport/Web.cs index 5a27469..7015653 100755 --- a/SendGrid/SendGridMail/Transport/Web.cs +++ b/SendGrid/SendGridMail/Transport/Web.cs @@ -107,7 +107,11 @@ namespace SendGridMail.Transport case "result":
break;
case "message": // success
- return;
+ bool errors = reader.ReadToNextSibling("errors");
+ if (errors)
+ throw new ProtocolViolationException(status);
+ else
+ return;
case "error": // failure
throw new ProtocolViolationException(status);
default:
|