From 86c28abacaad30873ab21c3c5b8e4a5a7813d306 Mon Sep 17 00:00:00 2001 From: Adam Date: Fri, 15 Feb 2013 12:12:57 +0100 Subject: [PATCH] Update library/Zend/Mail/Header/AbstractAddressList.php because [ErrorException] Notice: Undefined offset: 1 in vendor/zendframe work/zendframework/library/Zend/Mail/Header/AbstractAddressList.php line 46 --- library/Zend/Mail/Header/AbstractAddressList.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/library/Zend/Mail/Header/AbstractAddressList.php b/library/Zend/Mail/Header/AbstractAddressList.php index 97cbd5f1e6b..737e36fe65c 100644 --- a/library/Zend/Mail/Header/AbstractAddressList.php +++ b/library/Zend/Mail/Header/AbstractAddressList.php @@ -43,7 +43,9 @@ public static function fromString($headerLine) { $decodedLine = iconv_mime_decode($headerLine, ICONV_MIME_DECODE_CONTINUE_ON_ERROR, 'UTF-8'); // split into name/value - list($fieldName, $fieldValue) = explode(': ', $decodedLine, 2); + list($fieldName, $fieldValue) = explode(':', $decodedLine, 2); + $fieldName = \trim($fieldName); + $fieldValue = \trim($fieldValue); if (strtolower($fieldName) !== static::$type) { throw new Exception\InvalidArgumentException(sprintf(