diff --git a/src/qmldom/qqmldomtop.cpp b/src/qmldom/qqmldomtop.cpp index 57259c1659f..a295e430586 100644 --- a/src/qmldom/qqmldomtop.cpp +++ b/src/qmldom/qqmldomtop.cpp @@ -251,7 +251,7 @@ QPair>,std::shared_ptr>> { QMutexLocker l(mutex); auto it = map.find(canonicalPath); - if (it != map.cend() && (*it) && (*it)->current) { + if ((*it) && it != map.cend() && (*it)->current) { oldValue = *it; QString oldCode = oldValue->current->code(); QString newCode = newItem->code();