diff --git a/libsearch/filesystemwatcher/file-system-watcher.cpp b/libsearch/filesystemwatcher/file-system-watcher.cpp index 7bf197e..c4e4b89 100644 --- a/libsearch/filesystemwatcher/file-system-watcher.cpp +++ b/libsearch/filesystemwatcher/file-system-watcher.cpp @@ -208,12 +208,12 @@ void FileSystemWatcher::addWatchWithBlackList(const QStringList &pathList, const QStringList FileSystemWatcher::removeWatch(const QString &path) { - return d->removeWatch(path); for(QString watchedPath : d->m_watchedRootPaths) { if(FileUtils::isOrUnder(watchedPath, path)) { d->m_watchedRootPaths.removeAll(watchedPath); } } + return d->removeWatch(path); } void FileSystemWatcher::clearAll()