@@ -73,8 +73,8 @@ class SendGridTransport implements Swift_Transport
73
73
* (From SendGrid docs)
74
74
*/
75
75
const RESERVED_KEYWORDS = [
76
- 'x-sg-id ' , 'x-sg-eid ' , 'received ' , 'dkim-signature ' , 'Content-Type ' , 'Content-Transfer-Encoding ' ,
77
- 'To ' , 'From ' , 'Subject ' , 'Reply-To ' , 'CC ' , 'BCC '
76
+ 'X-SG-ID ' , 'X-SG-EID ' , 'RECEIVED ' , 'DKIM-SIGNATURE ' , 'CONTENT-TYPE ' , 'CONTENT-TRANSFER-ENCODING ' ,
77
+ 'TO ' , 'FROM ' , 'SUBJECT ' , 'REPLY-TO ' , 'CC ' , 'BCC '
78
78
];
79
79
80
80
public function __construct (Swift_Events_EventDispatcher $ eventDispatcher , $ sendGridApiKey , $ sendGridCategories )
@@ -233,7 +233,7 @@ public function send(Swift_Mime_SimpleMessage $message, &$failedRecipients = nul
233
233
if ($ headers = $ message ->getHeaders ()->getAll ()) {
234
234
foreach ($ headers as $ header ) {
235
235
$ headerName = $ header ->getFieldName ();
236
- if (!in_array ($ headerName , self ::RESERVED_KEYWORDS )) {
236
+ if (!in_array (strtoupper ( $ headerName) , self ::RESERVED_KEYWORDS )) {
237
237
$ mail ->addHeader ($ headerName , $ header ->getFieldBody ());
238
238
}
239
239
}
0 commit comments