diff options
author | Christoph Wurst <christoph@winzerhof-wurst.at> | 2018-02-01 19:06:56 +0300 |
---|---|---|
committer | Christoph Wurst <christoph@winzerhof-wurst.at> | 2018-02-01 19:06:56 +0300 |
commit | e138bd85aeeaa662cd6af41e4e4515f69a90b44f (patch) | |
tree | 6f3373e17f50c3ee99aff1a6703c7af832a88c05 /lib/Controller/MessagesController.php | |
parent | 5d6323a0a8b53323518273a1605f4552570383c8 (diff) |
Remove unified inbox/mailbox relicts
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'lib/Controller/MessagesController.php')
-rwxr-xr-x | lib/Controller/MessagesController.php | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/lib/Controller/MessagesController.php b/lib/Controller/MessagesController.php index 6f24dec65..c32f75c71 100755 --- a/lib/Controller/MessagesController.php +++ b/lib/Controller/MessagesController.php @@ -28,15 +28,14 @@ namespace OCA\Mail\Controller; +use OCA\Mail\Account; use OCA\Mail\Exception\ServiceException; use OCA\Mail\Http\AttachmentDownloadResponse; use OCA\Mail\Http\HtmlResponse; use OCA\Mail\Model\IMAPMessage; use OCA\Mail\Service\AccountService; -use OCA\Mail\Service\IAccount; use OCA\Mail\Service\IMailBox; use OCA\Mail\Service\Logger; -use OCA\Mail\Service\UnifiedAccount; use OCP\AppFramework\Controller; use OCP\AppFramework\Db\DoesNotExistException; use OCP\AppFramework\Http; @@ -72,7 +71,7 @@ class MessagesController extends Controller { /** @var IURLGenerator */ private $urlGenerator; - /** @var IAccount[] */ + /** @var Account[] */ private $accounts = []; /** @@ -153,14 +152,8 @@ class MessagesController extends Controller { $json = $this->enhanceMessage($accountId, $folderId, $id, $message, $mailBox); // Unified inbox hack + // TODO: evalue whether this is still in use on the client side $messageId = $id; - if ($accountId === UnifiedAccount::ID) { - // Add accountId, folderId for unified inbox replies - list($accountId, $messageId) = json_decode(base64_decode($id)); - $account = $this->getAccount($accountId); - $inbox = $account->getInbox(); - $folderId = base64_encode($inbox->getFolderId()); - } $json['messageId'] = $messageId; $json['accountId'] = $accountId; $json['folderId'] = $folderId; @@ -366,7 +359,7 @@ class MessagesController extends Controller { /** * @param int $accountId - * @return IAccount + * @return Account */ private function getAccount($accountId) { if (!array_key_exists($accountId, $this->accounts)) { |