diff options
author | Thomas Bruederli <thomas@roundcube.net> | 2012-09-09 20:23:56 +0200 |
---|---|---|
committer | Thomas Bruederli <thomas@roundcube.net> | 2012-09-09 20:23:56 +0200 |
commit | 99d9f50a0000447d0a752e6c43716237dc0da176 (patch) | |
tree | 0b958b9711d09c4da74f076e1b902ffa32a4a0a1 /program/include/rcube_imap.php | |
parent | a1303514933afe2d867067e4b95412c79652c89b (diff) | |
parent | 4e383e2ec8b4184c0fe74d02cf30fd3a4078128e (diff) |
Merge branch 'master' of github.com:roundcube/roundcubemail
Diffstat (limited to 'program/include/rcube_imap.php')
-rw-r--r-- | program/include/rcube_imap.php | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/program/include/rcube_imap.php b/program/include/rcube_imap.php index 4ab06cf60..66b5c4bd6 100644 --- a/program/include/rcube_imap.php +++ b/program/include/rcube_imap.php @@ -359,11 +359,11 @@ class rcube_imap extends rcube_storage return array( $this->search_string, - $this->search_set, - $this->search_charset, - $this->search_sort_field, - $this->search_sorted, - ); + $this->search_set, + $this->search_charset, + $this->search_sort_field, + $this->search_sorted, + ); } @@ -2138,14 +2138,17 @@ class rcube_imap extends rcube_storage /** * Sends the whole message source to stdout + * + * @param int $uid Message UID + * @param bool $formatted Enables line-ending formatting */ - public function print_raw_body($uid) + public function print_raw_body($uid, $formatted = true) { if (!$this->check_connection()) { return; } - $this->conn->handlePartBody($this->folder, $uid, true, NULL, NULL, true); + $this->conn->handlePartBody($this->folder, $uid, true, null, null, true, null, $formatted); } @@ -2219,6 +2222,10 @@ class rcube_imap extends rcube_storage $folder = $this->folder; } + if (!$this->check_connection()) { + return false; + } + // make sure folder exists if ($this->folder_exists($folder)) { if ($is_file) { @@ -3847,12 +3854,12 @@ class rcube_imap extends rcube_storage protected function rsort($folder, $delimiter, &$list, &$out) { while (list($key, $name) = each($list)) { - if (strpos($name, $folder.$delimiter) === 0) { - // set the type of folder name variable (#1485527) - $out[] = (string) $name; - unset($list[$key]); - $this->rsort($name, $delimiter, $list, $out); - } + if (strpos($name, $folder.$delimiter) === 0) { + // set the type of folder name variable (#1485527) + $out[] = (string) $name; + unset($list[$key]); + $this->rsort($name, $delimiter, $list, $out); + } } reset($list); } |