From: kink Date: Sun, 22 May 2005 13:11:58 +0000 (+0000) Subject: Handle missing flags column (in broken messages) a bit more gracefully X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=cc668b9fdbddd01dead57b807dda0968f075ad8b;p=squirrelmail.git Handle missing flags column (in broken messages) a bit more gracefully (ie without php-warnings). git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@9436 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/functions/mailbox_display.php b/functions/mailbox_display.php index 9f7b277a..4c6de6d7 100644 --- a/functions/mailbox_display.php +++ b/functions/mailbox_display.php @@ -600,6 +600,8 @@ function prepareMessageList(&$aMailbox, $aProps) { 'answered'=>false, 'flagged' => false, 'draft' => false); + + if(!is_array($value)) $value = array(); foreach ($value as $sFlag => $value) { switch ($sFlag) { case '\\seen' : $aFlagColumn['seen'] = true; break; @@ -1378,4 +1380,4 @@ function attachSelectedMessages($imapConnection,$aMsgHeaders) { return $composesession; } -?> \ No newline at end of file +?>