fix file extension search using '*' failing

This commit is contained in:
Jeremy Wu 2020-08-26 14:10:39 +10:00
parent 5661b20dfb
commit 0b368c2683

View file

@ -144,15 +144,17 @@ namespace Flow.Launcher.Plugin.Explorer.Search
private bool UseWindowsIndexForDirectorySearch(string locationPath)
{
var pathToDirectory = FilesFolders.ReturnPreviousDirectoryIfIncompleteString(locationPath);
if (!settings.UseWindowsIndexForDirectorySearch)
return false;
if (settings.IndexSearchExcludedSubdirectoryPaths
.Any(x => FilesFolders.ReturnPreviousDirectoryIfIncompleteString(locationPath)
.Any(x => FilesFolders.ReturnPreviousDirectoryIfIncompleteString(pathToDirectory)
.StartsWith(x.Path, StringComparison.OrdinalIgnoreCase)))
return false;
return indexSearch.PathIsIndexed(locationPath);
return indexSearch.PathIsIndexed(pathToDirectory);
}
}
}