From a0fad2513eff0105535b64ed118ed702e30014bc Mon Sep 17 00:00:00 2001
From: Nicolas Werner <nicolas.werner@hotmail.de>
Date: Mon, 1 Mar 2021 01:46:22 +0100
Subject: [PATCH] Don't ask to join joined rooms when clicking matrix uri

---
 src/ChatPage.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/ChatPage.cpp b/src/ChatPage.cpp
index aae9271da..c21c3571e 100644
--- a/src/ChatPage.cpp
+++ b/src/ChatPage.cpp
@@ -1419,7 +1419,7 @@ ChatPage::handleMatrixUri(const QByteArray &uri)
                 for (auto roomid : joined_rooms) {
                         if (roomid == targetRoomId) {
                                 room_list_->highlightSelectedRoom(mxid1);
-                                break;
+                                return;
                         }
                 }
 
@@ -1436,7 +1436,7 @@ ChatPage::handleMatrixUri(const QByteArray &uri)
                                 if (aliases->alias == targetRoomAlias) {
                                         room_list_->highlightSelectedRoom(
                                           QString::fromStdString(roomid));
-                                        break;
+                                        return;
                                 }
                         }
                 }
-- 
GitLab