From cea1155685009d3c4cfc3f7cca952bbcc385366d Mon Sep 17 00:00:00 2001 From: Michail Vourlakos Date: Mon, 22 Jul 2019 09:49:04 +0300 Subject: [PATCH] fix Importer::standardPath behavior --- app/layouts/importer.cpp | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/app/layouts/importer.cpp b/app/layouts/importer.cpp index 372be5463..155a4212e 100644 --- a/app/layouts/importer.cpp +++ b/app/layouts/importer.cpp @@ -220,19 +220,10 @@ QString Importer::standardPath(QString subPath, bool localfirst) { QStringList paths = standardPaths(localfirst); - if (localfirst) { - for(const auto &pt : paths) { - QString ptF = pt + "/" +subPath; - if (QFileInfo(ptF).exists()) { - return ptF; - } - } - } else { - for (int i=paths.count()-1; i>=0; i--) { - QString ptF = paths[i] + "/" +subPath; - if (QFileInfo(ptF).exists()) { - return ptF; - } + for(const auto &pt : paths) { + QString ptF = pt + "/" +subPath; + if (QFileInfo(ptF).exists()) { + return ptF; } }