Skip to content

Commit b4cb9dd

Browse files
Optimize LINQ usage in PathControlPointVisualiser and TestSceneSpinnerInput, and suppress NU1903
- PathControlPointVisualiser: Move totalCount calculation outside the loop and replace Where().Count() with Count(). - TestSceneSpinnerInput: Replace Where().Count() with Count(). - Directory.Build.props: Suppress NU1903 Build error due to AutoMapper 13.0.1 vulnerability.
1 parent bbeb688 commit b4cb9dd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

osu.Game.Rulesets.Osu.Tests/TestSceneSpinnerInput.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ void addSeekStep(double time)
280280

281281
private void assertTicksHit(int count)
282282
{
283-
AddAssert($"{count} ticks hit", () => judgementResults.Where(r => r.HitObject is SpinnerTick).Count(r => r.IsHit), () => Is.EqualTo(count));
283+
AddAssert($"{count} ticks hit", () => judgementResults.Count(r => r.HitObject is SpinnerTick && r.IsHit), () => Is.EqualTo(count));
284284
}
285285

286286
private void assertSpinnerHit(bool shouldBeHit)

0 commit comments

Comments
 (0)