From: Michael M Slusarz Date: Tue, 4 May 2010 09:51:21 +0000 (-0600) Subject: Don't add empty mailbox arrays X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=86f262fc7f5e48d3554c20978f07f9cadd4a4f6b;p=horde.git Don't add empty mailbox arrays --- diff --git a/imp/lib/Indices.php b/imp/lib/Indices.php index 69d601e92..8609be485 100644 --- a/imp/lib/Indices.php +++ b/imp/lib/Indices.php @@ -100,9 +100,14 @@ class IMP_Indices implements Iterator case 2: $secondarg = func_get_arg(1); - $indices = array( - func_get_arg(0) => (is_array($secondarg) ? array_keys(array_flip($secondarg)) : array($secondarg)) - ); + $secondarg = is_array($secondarg) + ? array_keys(array_flip($secondarg)) + : array($secondarg); + if (!empty($secondarg)) { + $indices = array( + func_get_arg(0) => $secondarg + ); + } break; }