tangled
alpha
login
or
join now
keii.dev
/
osu-framework
0
fork
atom
A game framework written with osu! in mind.
0
fork
atom
overview
issues
pulls
pipelines
Replace string.IndexOf calls with string.Contains
Bartłomiej Dach
5 years ago
fe1944db
af924b52
+2
-2
2 changed files
expand all
collapse all
unified
split
osu.Framework
Graphics
Containers
SearchContainer.cs
IO
Stores
IResourceStore.cs
+1
-1
osu.Framework/Graphics/Containers/SearchContainer.cs
reviewed
···
69
69
//Words matched by parent is not needed to match children
70
70
var childTerms = terms.Where(term =>
71
71
!filterable.FilterTerms.Any(filterTerm =>
72
72
-
filterTerm.IndexOf(term, StringComparison.InvariantCultureIgnoreCase) >= 0)).ToArray();
72
72
+
filterTerm.Contains(term, StringComparison.InvariantCultureIgnoreCase))).ToArray();
73
73
74
74
bool matching = childTerms.Length == 0;
75
75
+1
-1
osu.Framework/IO/Stores/IResourceStore.cs
reviewed
···
78
78
/// <param name="source">A list of filenames.</param>
79
79
/// <returns>A list of filenames excluding common system files.</returns>
80
80
public static IEnumerable<string> ExcludeSystemFileNames(this IEnumerable<string> source) =>
81
81
-
source.Where(entry => !system_filename_ignore_list.Any(ignoredName => entry.IndexOf(ignoredName, StringComparison.OrdinalIgnoreCase) >= 0));
81
81
+
source.Where(entry => !system_filename_ignore_list.Any(ignoredName => entry.Contains(ignoredName, StringComparison.OrdinalIgnoreCase)));
82
82
}
83
83
}