Showing the changes to libraries/script-engine/src/ScriptsModel.cpp (1 of 4 files). Show all
Unified · Split
| @@ -309,6 +309,9 @@ void ScriptsModel::rebuildTree() { · 308 unmodified lines | ||
| 309 | 309 | QString hash; |
| 310 | 310 | QStringList pathList = script->getLocalPath().split(tr("/")); |
| 311 | 311 | pathList.removeLast(); |
| 312 | + if (pathList.isEmpty()) { | |
| 313 | + continue; | |
| 314 | + } | |
| 312 | 315 | QStringList::const_iterator pathIterator; |
| 313 | 316 | for (pathIterator = pathList.constBegin(); pathIterator != pathList.constEnd(); ++pathIterator) { |
| 314 | 317 | hash.append(*pathIterator + "/"); |