mirror of
https://github.com/chatmail/core.git
synced 2026-04-06 23:52:11 +03:00
Received messages shouldn't mingle with just sent ones and appear somewhere in the middle of the chat, so we go after the newest non fresh message. But if a received outgoing message is older than some `InSeen` message, better sort the received message purely by timestamp (this is an heuristic in order not to break the Gmail-like case simulated by `verified_chats::test_old_message_4()`). We could place the received message just before that `InSeen` message, but anyway the user may not notice it. At least this fixes outgoing messages sorting for shared accounts where messages from other devices should be sorted the same way as incoming ones.