summary refs log tree commit diff
path: root/src/timeline/TimelineModel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/timeline/TimelineModel.cpp')
-rw-r--r--src/timeline/TimelineModel.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/timeline/TimelineModel.cpp b/src/timeline/TimelineModel.cpp
index 4b74b3bd..48b58ee5 100644
--- a/src/timeline/TimelineModel.cpp
+++ b/src/timeline/TimelineModel.cpp
@@ -2246,8 +2246,9 @@ TimelineModel::getRoomVias(const QString &roomId)
 void
 TimelineModel::copyLinkToEvent(const QString &eventId) const
 {
-    auto link = QStringLiteral("%1/%2?%3")
-                  .arg(getBareRoomLink(room_id_),
+    // Event links shouldn't use an alias, since that can be repointed.
+    auto link = QStringLiteral("https://matrix.to/#/%1/%2?%3")
+                  .arg(QUrl::toPercentEncoding(room_id_),
                        QString(QUrl::toPercentEncoding(eventId)),
                        getRoomVias(room_id_));
     QGuiApplication::clipboard()->setText(link);