Use Contains instead of IndexOf
MODIFY
WalletWasabi.Fluent/ViewModels/SearchPageViewModel.cs
WalletWasabi.Fluent/ViewModels/SearchPageViewModel.cs
@@ -72,10 +72,10 @@ namespace WalletWasabi.Fluent.ViewModels
return item =>
{
if (!string.IsNullOrWhiteSpace(searchQuery)
- && searchQuery.IndexOf(',', StringComparison.OrdinalIgnoreCase) < 0)
+ && !searchQuery.Contains(',', StringComparison.OrdinalIgnoreCase))
{
- return item.Keywords.IndexOf(searchQuery, StringComparison.OrdinalIgnoreCase) >= 0 ||
- item.Caption.IndexOf(searchQuery, StringComparison.OrdinalIgnoreCase) >= 0;
+ return item.Keywords.Contains(searchQuery, StringComparison.OrdinalIgnoreCase) ||
+ item.Caption.Contains(searchQuery, StringComparison.OrdinalIgnoreCase);
}
return true;
};

Use Contains instead of IndexOf