summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Kamm <mail@ckamm.de>2020-05-19 11:18:45 +0200
committerChristian Kamm <mail@ckamm.de>2020-05-21 07:53:24 +0000
commit338fa26bc37ab1180090c3d7b58c5097cb10e70e (patch)
tree654c55fcd4e253649b0b0bfa0f169ec8ed2f66a4
parent96c860159b862460e21be16a6e2839c0b591e016 (diff)
downloadqt-creator-338fa26bc37ab1180090c3d7b58c5097cb10e70e.tar.gz
QmlJS: Scan import paths, even if there is only one
Previously a single QML import path would not be scanned. This did not usually happen to users, as there's almost always more than one path. But it could lead to unexpected behavior in tests that explicitly controled import paths. Change-Id: I015f44f183ad484c333ab7a4e5e98b87098620a7 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
-rw-r--r--src/libs/qmljs/qmljsmodelmanagerinterface.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libs/qmljs/qmljsmodelmanagerinterface.cpp b/src/libs/qmljs/qmljsmodelmanagerinterface.cpp
index 3376cc3762..1eb54f7303 100644
--- a/src/libs/qmljs/qmljsmodelmanagerinterface.cpp
+++ b/src/libs/qmljs/qmljsmodelmanagerinterface.cpp
@@ -1133,7 +1133,7 @@ void ModelManagerInterface::maybeScan(const PathsAndLanguages &importPaths)
pathToScan.maybeInsert(importPath);
}
- if (pathToScan.length() > 1) {
+ if (pathToScan.length() >= 1) {
QFuture<void> result = Utils::runAsync(&ModelManagerInterface::importScan,
workingCopyInternal(), pathToScan,
this, true, true, false);