From 3fcc166e4adf4156865e9d1ce74f8ab01f0a9739 Mon Sep 17 00:00:00 2001 From: "Michael J. Rubinsky" Date: Sat, 17 Jan 2009 17:08:39 -0500 Subject: [PATCH] Checking existence for an array element on a string will always evaluate to 'true' - need to add additional checks for an array here as well. --- framework/Mime/lib/Horde/Mime.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/Mime/lib/Horde/Mime.php b/framework/Mime/lib/Horde/Mime.php index a0dcfa062..f201be61f 100644 --- a/framework/Mime/lib/Horde/Mime.php +++ b/framework/Mime/lib/Horde/Mime.php @@ -209,8 +209,8 @@ class Horde_Mime $text = ''; foreach ($addresses as $addr) { // Check for groups. - if (empty($addr['groupname'])) { - if (empty($addr['personal'])) { + if (!is_array($addr) || (is_array($addr) && empty($addr['groupname']))) { + if (!is_array($addr) || (is_array($addr) && empty($addr['personal']))) { $personal = ''; } else { if (($addr['personal'][0] == '"') && -- 2.11.0