summary refs log tree commit diff
path: root/src/timeline
diff options
context:
space:
mode:
authorLoren Burkholder <computersemiexpert@outlook.com>2021-06-11 20:46:57 -0400
committerLoren Burkholder <computersemiexpert@outlook.com>2021-07-20 21:47:22 -0400
commita176de5f11f11bb3dad6cb8ea71a3b5edd6f27f4 (patch)
treee5c3029a89923cf2d67bd981432f9e61c0b9480f /src/timeline
parentGet member info loading working (diff)
downloadnheko-a176de5f11f11bb3dad6cb8ea71a3b5edd6f27f4.tar.xz
Make sure to use the default room id if none is specified
Diffstat (limited to 'src/timeline')
-rw-r--r--src/timeline/TimelineModel.cpp6
-rw-r--r--src/timeline/TimelineModel.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/timeline/TimelineModel.cpp b/src/timeline/TimelineModel.cpp
index 2127801c..ebbca6f4 100644
--- a/src/timeline/TimelineModel.cpp
+++ b/src/timeline/TimelineModel.cpp
@@ -1077,11 +1077,11 @@ TimelineModel::openRoomSettings(QString room_id)
 }
 
 void
-TimelineModel::openInviteUsers(QString room_id)
+TimelineModel::openInviteUsers(QString roomId)
 {
         InviteesModel *model = new InviteesModel{this};
-        connect(model, &InviteesModel::accept, this, [this, model, room_id]() {
-                manager_->inviteUsers(room_id, model->mxids());
+        connect(model, &InviteesModel::accept, this, [this, model, roomId]() {
+                manager_->inviteUsers(roomId == QString() ? room_id_ : roomId, model->mxids());
         });
         openInviteUsersDialog(model);
 }
diff --git a/src/timeline/TimelineModel.h b/src/timeline/TimelineModel.h
index e5189e61..b5144308 100644
--- a/src/timeline/TimelineModel.h
+++ b/src/timeline/TimelineModel.h
@@ -240,7 +240,7 @@ public:
         Q_INVOKABLE void openUserProfile(QString userid);
         Q_INVOKABLE void openRoomMembers();
         Q_INVOKABLE void openRoomSettings(QString room_id = QString());
-        Q_INVOKABLE void openInviteUsers(QString room_id = QString());
+        Q_INVOKABLE void openInviteUsers(QString roomId = QString());
         Q_INVOKABLE void editAction(QString id);
         Q_INVOKABLE void replyAction(QString id);
         Q_INVOKABLE void readReceiptsAction(QString id) const;