Only need to increment thread level if in base.
authorMichael M Slusarz <slusarz@curecanti.org>
Tue, 9 Dec 2008 07:02:27 +0000 (00:02 -0700)
committerMichael M Slusarz <slusarz@curecanti.org>
Tue, 9 Dec 2008 22:23:25 +0000 (15:23 -0700)
framework/Imap_Client/lib/Horde/Imap/Client/Socket.php

index 5969473..d3ddff0 100644 (file)
@@ -1923,7 +1923,7 @@ class Horde_Imap_Client_Socket extends Horde_Imap_Client_Base
         reset($data);
         while (list($key, $val) = each($data)) {
             if (is_array($val)) {
-                $this->_parseThread($val, $level + 1, ($key == $cnt));
+                $this->_parseThread($val, $level ? $level : 1, ($key == $cnt));
             } else {
                 if (is_null($tp['base']) && ($level || $cnt)) {
                     $tp['base'] = $val;