From 08f391fcd7411084c3c88c2451892d52ad202879 Mon Sep 17 00:00:00 2001 From: the-djmaze <> Date: Mon, 20 Feb 2023 15:15:52 +0100 Subject: [PATCH] bugfix: threads indicator gets lost with new message cache handling --- snappymail/v/0.0.0/app/libraries/MailSo/Mail/Message.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/snappymail/v/0.0.0/app/libraries/MailSo/Mail/Message.php b/snappymail/v/0.0.0/app/libraries/MailSo/Mail/Message.php index 1bb620a4d..980431b0f 100644 --- a/snappymail/v/0.0.0/app/libraries/MailSo/Mail/Message.php +++ b/snappymail/v/0.0.0/app/libraries/MailSo/Mail/Message.php @@ -493,7 +493,7 @@ class Message implements \JsonSerializable } } - return array( + $result = array( '@Object' => 'Object/Message', 'folder' => $this->sFolder, 'uid' => $this->Uid, @@ -517,7 +517,6 @@ class Message implements \JsonSerializable 'deliveredTo' => $this->oDeliveredTo, 'priority' => $this->iPriority, - 'threads' => $this->aThreads, 'unsubsribeLinks' => $this->UnsubsribeLinks, 'readReceipt' => '', 'autocrypt' => $aAutocrypt ?: null, @@ -540,5 +539,11 @@ class Message implements \JsonSerializable // 'keywords' => $keywords, 'size' => $this->iSize ); + + if ($this->aThreads) { + $result['threads'] = $this->aThreads; + } + + return $result; } }