aboutsummaryrefslogtreecommitdiff
path: root/lib/room.cpp
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2018-12-13 19:56:18 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2018-12-13 19:56:18 +0900
commit2cbb053faeae1f23606c56ef9fd9d13ca4a2dd21 (patch)
treea1b22bc0ccc098b5b183a795758c047d54614224 /lib/room.cpp
parentcf4759edba82baf51dd40285d2e13b200ca7fd29 (diff)
downloadlibquotient-2cbb053faeae1f23606c56ef9fd9d13ca4a2dd21.tar.gz
libquotient-2cbb053faeae1f23606c56ef9fd9d13ca4a2dd21.zip
Room::getAllMembers: fix off-by-one error
Diffstat (limited to 'lib/room.cpp')
-rw-r--r--lib/room.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/room.cpp b/lib/room.cpp
index 7232741a..8f9095dd 100644
--- a/lib/room.cpp
+++ b/lib/room.cpp
@@ -595,7 +595,7 @@ Room::rev_iter_t Room::findInTimeline(const QString& evtId) const
void Room::Private::getAllMembers()
{
// If already loaded or already loading, there's nothing to do here.
- if (q->joinedCount() <= membersMap.size() || isJobRunning(allMembersJob))
+ if (q->joinedCount() - 1 <= membersMap.size() || isJobRunning(allMembersJob))
return;
allMembersJob = connection->callApi<GetMembersByRoomJob>(