Hopefully fixes problem with "wrong datatype for second argument to in_array"
authorfidian <fidian@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Fri, 2 Feb 2001 21:00:31 +0000 (21:00 +0000)
committerfidian <fidian@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Fri, 2 Feb 2001 21:00:31 +0000 (21:00 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1047 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/mailbox_display.php

index c51dd74..1e4b69c 100644 (file)
 
       $boxes = sqimap_mailbox_list($imapConnection);
       for ($i = 0; $i < count($boxes); $i++) {
-         if (!in_array("noselect", $boxes[$i]["flags"])) {
+         if (!is_array($boxes[$i]['flags']) ||
+            !in_array("noselect", $boxes[$i]['flags'])) {
             $box = $boxes[$i]['unformatted'];
             $box2 = replace_spaces($boxes[$i]['unformatted-disp']);
             echo "         <OPTION VALUE=\"$box\">$box2</option>\n";