From f88d417c96119b8e50297b930b14fe6ff9a1c5ed Mon Sep 17 00:00:00 2001 From: thomascube <thomas@roundcube.net> Date: Sun, 19 Feb 2006 13:34:34 -0500 Subject: [PATCH] Applied several patches --- program/include/rcube_imap.inc | 23 ++++++++++++++--------- 1 files changed, 14 insertions(+), 9 deletions(-) diff --git a/program/include/rcube_imap.inc b/program/include/rcube_imap.inc index 400d0c0..50264ac 100644 --- a/program/include/rcube_imap.inc +++ b/program/include/rcube_imap.inc @@ -865,7 +865,7 @@ { $mailbox = $this->_mod_mailbox($mbox); - // make shure mailbox exists + // make sure mailbox exists if (in_array($mailbox, $this->_list_mailboxes())) $saved = iil_C_Append($this->conn, $mailbox, $message); @@ -885,10 +885,15 @@ $to_mbox = $this->_mod_mailbox($to_mbox); $from_mbox = $from_mbox ? $this->_mod_mailbox($from_mbox) : $this->mailbox; - // make shure mailbox exists + // make sure mailbox exists if (!in_array($to_mbox, $this->_list_mailboxes())) - return FALSE; - + { + if (in_array(strtolower($to_mbox), $this->default_folders)) + $this->create_mailbox($to_mbox, TRUE); + else + return FALSE; + } + // convert the list of uids to array $a_uids = is_string($uids) ? explode(',', $uids) : (is_array($uids) ? $uids : NULL); @@ -1473,10 +1478,10 @@ $key, $index, $headers->uid, - substr($this->decode_header((string)$headers->subject, TRUE), 0, 128), - substr($this->decode_header((string)$headers->from, TRUE), 0, 128), - substr($this->decode_header((string)$headers->to, TRUE), 0, 128), - substr($this->decode_header((string)$headers->cc, TRUE), 0, 128), + substr((string)$this->decode_header($headers->subject, TRUE), 0, 128), + substr((string)$this->decode_header($headers->from, TRUE), 0, 128), + substr((string)$this->decode_header($headers->to, TRUE), 0, 128), + substr((string)$this->decode_header($headers->cc, TRUE), 0, 128), (int)$headers->size, serialize($headers)); } @@ -1931,4 +1936,4 @@ return trim($output); } -?> +?> \ No newline at end of file -- Gitblit v1.9.1