From: Michael M Slusarz Date: Fri, 6 Feb 2009 06:05:27 +0000 (-0700) Subject: Don't remove message from list when copying X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=75376cb4757f55ee95aefa4d91e0971a8baa6ea2;p=horde.git Don't remove message from list when copying --- diff --git a/imp/lib/Message.php b/imp/lib/Message.php index 16edd3772..820a33281 100644 --- a/imp/lib/Message.php +++ b/imp/lib/Message.php @@ -19,6 +19,9 @@ class IMP_Message { /** + * The singleton IMP_Message instance + * + * @var IMP_Message */ protected static $_instance = null; @@ -30,9 +33,9 @@ class IMP_Message protected $_usepop = false; /** - * Returns a reference to the global IMP_Message object, only creating it if - * it doesn't already exist. This ensures that only one IMP_Message instance - * is instantiated for any given session. + * Returns a reference to the global IMP_Message object, only creating it + * if it doesn't already exist. This ensures that only one IMP_Message + * instance is instantiated for any given session. * * @return IMP_Message The IMP_Message instance. */ @@ -126,7 +129,7 @@ class IMP_Message $GLOBALS['imp_imap']->ob->copy($mbox, $targetMbox, array('ids' => $msgIndices, 'move' => $imap_move)); $imp_mailbox = IMP_Mailbox::singleton($mbox); - if ($imp_mailbox->isBuilt()) { + if (($action == 'move') && $imp_mailbox->isBuilt()) { $imp_mailbox->removeMsgs(array($mbox => $msgIndices)); } } catch (Horde_Imap_Client_Exception $e) {