Commit 1c2dd7ad authored by Alexander Lohnau's avatar Alexander Lohnau 💬 Committed by Laurent Montel
Browse files

Remove custom logic for avoiding duplicate plugins

This is now done in KCoreAddons with frameworks/kcoreaddons@e99a8eaa
and consequently the logic is not needed anymore.

Task: https://phabricator.kde.org/T12154
parent 435d82f7
Pipeline #65806 passed with stage
in 6 minutes and 18 seconds
......@@ -44,7 +44,6 @@ bool ImportMailPluginManager::initializePluginList()
QVectorIterator<KPluginMetaData> i(plugins);
i.toBack();
QSet<QString> unique;
while (i.hasPrevious()) {
ImportMailPluginManagerInfo info;
const KPluginMetaData data = i.previous();
......@@ -55,13 +54,8 @@ bool ImportMailPluginManager::initializePluginList()
info.metaDataFileNameBaseName = QFileInfo(data.fileName()).baseName();
info.metaDataFileName = data.fileName();
if (pluginVersion() == data.version()) {
// only load plugins once, even if found multiple times!
if (unique.contains(info.metaDataFileNameBaseName)) {
continue;
}
info.plugin = nullptr;
mPluginList.push_back(info);
unique.insert(info.metaDataFileNameBaseName);
} else {
qCWarning(IMPORTWIZARD_LOG) << "Plugin " << data.name() << " doesn't have correction plugin version. It will not be loaded.";
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment