Git commit 161a8c06b2da31c9362c53546bd2192eac540fb1 by Aleix Pol. Committed on 31/07/2017 at 23:51. Pushed by apol into branch 'master'. Proper variable scope, adequate API M +2 -3 duchain/helpers.cpp https://commits.kde.org/kdev-python/161a8c06b2da31c9362c53546bd2192eac540fb1 diff --git a/duchain/helpers.cpp b/duchain/helpers.cpp index 2499bf86..6416f954 100644 --- a/duchain/helpers.cpp +++ b/duchain/helpers.cpp @@ -452,10 +452,9 @@ QVector Helper::getSearchPaths(const QUrl& worki= ngOnDocument) python.start(getPythonExecutablePath(project), getpath); python.waitForFinished(1000); QString pythonpath =3D QString::fromUtf8(python.readAllStandardOut= put()); - auto paths =3D pythonpath.split("$|$"); - paths.removeAll(""); - = + if ( ! pythonpath.isEmpty() ) { + const auto paths =3D pythonpath.split("$|$", QString::SkipEmpt= yParts); foreach ( const QString& path, paths ) { cachedForProject.append(QUrl::fromLocalFile(path)); }