From: Michael J. Rubinsky Date: Mon, 7 Dec 2009 19:43:05 +0000 (-0500) Subject: Need $s_res if $list_msgs is true as well. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=b3a1e38ea1e60e466a4db24cb5de0a55edc3d1d0;p=horde.git Need $s_res if $list_msgs is true as well. Bug: 8752 --- diff --git a/framework/Imap_Client/lib/Horde/Imap/Client/Socket.php b/framework/Imap_Client/lib/Horde/Imap/Client/Socket.php index ccc0aaa33..ee088ebb4 100644 --- a/framework/Imap_Client/lib/Horde/Imap/Client/Socket.php +++ b/framework/Imap_Client/lib/Horde/Imap/Client/Socket.php @@ -1426,19 +1426,19 @@ class Horde_Imap_Client_Socket extends Horde_Imap_Client_Base } } + $list_msgs = !empty($options['list']); + $tmp = &$this->_temp; + $tmp['expunge'] = $tmp['vanished'] = array(); + /* We need to get sequence num -> UID lookup table if we are caching. * There is no guarantee that if we are using QRESYNC that we will get * VANISHED responses, so this is necessary. */ - if ($use_cache && is_null($s_res)) { + if (($list_msgs || $use_cache) && is_null($s_res)) { /* Keys in $s_res['sort'] start at 0, not 1. */ $s_res = $this->_getSeqUIDLookup(null, false); $s_res['sort'] = $s_res['uids']; } - $tmp = &$this->_temp; - $tmp['expunge'] = $tmp['vanished'] = array(); - $list_msgs = !empty($options['list']); - /* Always use UID EXPUNGE if available. */ if ($uidplus) { $this->_sendLine('UID EXPUNGE ' . $uid_string);