Fix incorrect sort order when the user was removed
authorMarcel Werk <burntime@woltlab.com>
Fri, 14 Jul 2023 15:17:18 +0000 (17:17 +0200)
committerMarcel Werk <burntime@woltlab.com>
Fri, 14 Jul 2023 15:17:18 +0000 (17:17 +0200)
See https://www.woltlab.com/community/thread/295198-sortierung-von-konversationen-fehlerhaft-wenn-teilnehmer-entfernt-wird/?postID=1931772#post1931772

files/lib/data/conversation/UserConversationList.class.php

index a0fa5b614d154ead3d9d3810987278f234084369..305250a2e4d17a62a67b77c5be84c1be5be5de75 100644 (file)
@@ -106,6 +106,7 @@ class UserConversationList extends ConversationList
             conversation.*,
             (CASE
                 WHEN    conversation_to_user.leftAt <> 0
+                        AND conversation.lastPostTime > conversation_to_user.leftAt
                 THEN    conversation_to_user.leftAt
                 ELSE    conversation.lastPostTime
             END) AS lastPostTime";