From f238c18ce880055e12f0ddc8ec00f64b4837e3d4 Mon Sep 17 00:00:00 2001 From: Brent Mackey Date: Tue, 10 Jan 2023 20:59:31 +1000 Subject: [PATCH] Fix last message read receipt reporting time in GMT instead of localtime --- src/messageeventmodel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/messageeventmodel.cpp b/src/messageeventmodel.cpp index 23dfaf7d7..1ab72c703 100644 --- a/src/messageeventmodel.cpp +++ b/src/messageeventmodel.cpp @@ -439,7 +439,7 @@ QVariant MessageEventModel::data(const QModelIndex &idx, int role) const case EventTypeRole: return DelegateType::ReadMarker; case TimeRole: { - const QDateTime eventDate = data(index(m_lastReadEventIndex.row() + 1, 0), TimeRole).toDateTime(); + const QDateTime eventDate = data(index(m_lastReadEventIndex.row() + 1, 0), TimeRole).toDateTime().toLocalTime(); const KFormat format; return format.formatRelativeDateTime(eventDate, QLocale::ShortFormat); }