mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 07:33:55 +09:00
Apply batch fixing of built-in types using var
This commit is contained in:
@ -57,9 +57,9 @@ namespace osu.Game.Screens.Select.Carousel
|
||||
|
||||
if (match)
|
||||
{
|
||||
var terms = BeatmapInfo.GetSearchableTerms();
|
||||
string[] terms = BeatmapInfo.GetSearchableTerms();
|
||||
|
||||
foreach (var criteriaTerm in criteria.SearchTerms)
|
||||
foreach (string criteriaTerm in criteria.SearchTerms)
|
||||
match &= terms.Any(term => term.Contains(criteriaTerm, StringComparison.InvariantCultureIgnoreCase));
|
||||
|
||||
// if a match wasn't found via text matching of terms, do a second catch-all check matching against online IDs.
|
||||
@ -89,7 +89,7 @@ namespace osu.Game.Screens.Select.Carousel
|
||||
{
|
||||
default:
|
||||
case SortMode.Difficulty:
|
||||
var ruleset = BeatmapInfo.RulesetID.CompareTo(otherBeatmap.BeatmapInfo.RulesetID);
|
||||
int ruleset = BeatmapInfo.RulesetID.CompareTo(otherBeatmap.BeatmapInfo.RulesetID);
|
||||
if (ruleset != 0) return ruleset;
|
||||
|
||||
return BeatmapInfo.StarDifficulty.CompareTo(otherBeatmap.BeatmapInfo.StarDifficulty);
|
||||
|
@ -95,8 +95,8 @@ namespace osu.Game.Screens.Select.Carousel
|
||||
|
||||
private int compareUsingAggregateMax(CarouselBeatmapSet other, Func<BeatmapInfo, double> func)
|
||||
{
|
||||
var ourBeatmaps = ValidBeatmaps.Any();
|
||||
var otherBeatmaps = other.ValidBeatmaps.Any();
|
||||
bool ourBeatmaps = ValidBeatmaps.Any();
|
||||
bool otherBeatmaps = other.ValidBeatmaps.Any();
|
||||
|
||||
if (!ourBeatmaps && !otherBeatmaps) return 0;
|
||||
if (!ourBeatmaps) return -1;
|
||||
|
@ -241,7 +241,7 @@ namespace osu.Game.Screens.Select.Carousel
|
||||
|
||||
TernaryState state;
|
||||
|
||||
var countExisting = beatmapSet.Beatmaps.Count(b => collection.Beatmaps.Contains(b));
|
||||
int countExisting = beatmapSet.Beatmaps.Count(b => collection.Beatmaps.Contains(b));
|
||||
|
||||
if (countExisting == beatmapSet.Beatmaps.Count)
|
||||
state = TernaryState.True;
|
||||
|
Reference in New Issue
Block a user