aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--autotests/kconfigtest.cpp2
-rw-r--r--src/core/kconfig.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/autotests/kconfigtest.cpp b/autotests/kconfigtest.cpp
index e6a3e645..bf7882f0 100644
--- a/autotests/kconfigtest.cpp
+++ b/autotests/kconfigtest.cpp
@@ -802,7 +802,7 @@ void KConfigTest::testDelete()
delgr.deleteGroup();
QVERIFY(!delgr.exists());
QVERIFY(!ct.hasGroup("Nested Group 3"));
- QVERIFY(!ct.groupList().contains(QStringLiteral("Nested Group 3")));
+ QVERIFY(ct.groupList().contains(QStringLiteral("Nested Group 3")));
KConfigGroup ng(&ct, "Nested Group 2");
QVERIFY(sc.hasGroup("Complex Types"));
diff --git a/src/core/kconfig.cpp b/src/core/kconfig.cpp
index 49a66d14..cc3700e1 100644
--- a/src/core/kconfig.cpp
+++ b/src/core/kconfig.cpp
@@ -269,7 +269,7 @@ QStringList KConfig::groupList() const
for (auto entryMapIt = d->entryMap.cbegin(); entryMapIt != d->entryMap.cend(); ++entryMapIt) {
const KEntryKey &key = entryMapIt.key();
const QByteArray group = key.mGroup;
- if (key.mKey.isNull() && !group.isEmpty() && group != "<default>" && group != "$Version" && !d->hasNonDeletedEntries(group)) {
+ if (key.mKey.isNull() && !group.isEmpty() && group != "<default>" && group != "$Version") {
const QString groupname = QString::fromUtf8(group);
groups << groupname.left(groupname.indexOf(QLatin1Char('\x1d')));
}
@@ -285,7 +285,7 @@ QStringList KConfigPrivate::groupList(const QByteArray &group) const
for (auto entryMapIt = entryMap.cbegin(); entryMapIt != entryMap.cend(); ++entryMapIt) {
const KEntryKey &key = entryMapIt.key();
- if (key.mKey.isNull() && key.mGroup.startsWith(theGroup) && !hasNonDeletedEntries(group)) {
+ if (key.mKey.isNull() && key.mGroup.startsWith(theGroup)) {
const QString groupname = QString::fromUtf8(key.mGroup.mid(theGroup.length()));
groups << groupname.left(groupname.indexOf(QLatin1Char('\x1d')));
}