aboutsummaryrefslogtreecommitdiffstats
path: root/src/qmlls/qqmllsutils.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/qmlls/qqmllsutils.cpp')
-rw-r--r--src/qmlls/qqmllsutils.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/qmlls/qqmllsutils.cpp b/src/qmlls/qqmllsutils.cpp
index 36a98ff329..7251e5aeac 100644
--- a/src/qmlls/qqmllsutils.cpp
+++ b/src/qmlls/qqmllsutils.cpp
@@ -184,9 +184,12 @@ QList<QQmlLSUtilsItemLocation> QQmlLSUtils::itemsFromTextLocation(DomItem file,
if (containsTarget(subLoc->info().fullRegion)) {
QQmlLSUtilsItemLocation subItem;
subItem.domItem = iLoc.domItem.path(it.key());
- Q_ASSERT_X(subItem.domItem, "QQmlLSUtils::itemsFromTextLocation",
- "A DomItem child is missing or the FileLocationsTree structure does not "
- "follow the DomItem Structure.");
+ if (!subItem.domItem) {
+ qCDebug(QQmlLSUtilsLog)
+ << "A DomItem child is missing or the FileLocationsTree structure does "
+ "not follow the DomItem Structure.";
+ continue;
+ }
subItem.fileLocation = subLoc;
toDo.append(subItem);
inParentButOutsideChildren = false;