Skip to content
This repository has been archived by the owner on Dec 27, 2023. It is now read-only.

Commit

Permalink
fix(Felamimail/Message): fix forwarding eml message from Filemanager
Browse files Browse the repository at this point in the history
  • Loading branch information
pschuele committed Aug 17, 2021
1 parent ba00deb commit a01018d
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions tine20/Felamimail/Controller/Message/Send.php
Original file line number Diff line number Diff line change
Expand Up @@ -205,9 +205,16 @@ protected function _resolveOriginalMessage(Felamimail_Model_Message $_message)
try {
$originalMessage = ($originalMessageId) ? $this->get($originalMessageId) : NULL;
} catch (Tinebase_Exception_NotFound $tenf) {
if (Tinebase_Core::isLogLevel(Zend_Log::DEBUG)) Tinebase_Core::getLogger()->debug(__METHOD__ . '::' . __LINE__
. ' Did not find original message (' . $originalMessageId . ')');
$originalMessage = NULL;
try {
// maybe original id was a tree node (sent from Filemanager)
$originalMessage = Felamimail_Controller_Message::getInstance()->getMessageFromNode($originalMessageId);
$partId = 1;
} catch (Tinebase_Exception_NotFound $tenf) {
if (Tinebase_Core::isLogLevel(Zend_Log::DEBUG)) Tinebase_Core::getLogger()->debug(__METHOD__ . '::' . __LINE__
. ' Did not find original message (' . $originalMessageId . ')');
$translation = Tinebase_Translation::getTranslation('Felamimail');
throw new Tinebase_Exception_NotFound($translation->_('Original message not found, email was moved or deleted'));
}
}

$_message->original_id = $originalMessage;
Expand Down

0 comments on commit a01018d

Please sign in to comment.