[network/ruqola] src/core/model: Use parseMoreModerationInfos

Laurent Montel <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit ebd503e90621bee663ec550f4599e019e579f465 by Laurent Montel.
Committed on 13/08/2026 at 18:14.
Pushed by mlaurent into branch 'master'.

Use parseMoreModerationInfos

M  +5    -3    src/core/model/moderationreportedmessagemodel.cpp

https://invent.kde.org/network/ruqola/-/commit/ebd503e90621bee663ec550f4599e019e579f465

diff --git a/src/core/model/moderationreportedmessagemodel.cpp b/src/core/model/moderationreportedmessagemodel.cpp
index 8c1c5c52ed..5d7791bc0f 100644
--- a/src/core/model/moderationreportedmessagemodel.cpp
+++ b/src/core/model/moderationreportedmessagemodel.cpp
@@ -141,9 +141,11 @@ void ModerationReportedMessageModel::setModerationInfos(const ModerationReported
 void ModerationReportedMessageModel::addMoreElements(const QJsonObject &obj)
 {
     const int numberOfElement = mModerationInfos.count();
-    mModerationInfos.parseModerationInfos(obj);
-    beginInsertRows(QModelIndex(), numberOfElement, mModerationInfos.count() - 1);
-    endInsertRows();
+    mModerationInfos.parseMoreModerationInfos(obj);
+    if (mModerationInfos.count() > numberOfElement) {
+        beginInsertRows(QModelIndex(), numberOfElement, mModerationInfos.count() - 1);
+        endInsertRows();
+    }
     checkFullList();
 }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.