Fix potential test failure in daily challenge tests

See https://github.com/ppy/osu/actions/runs/10296877688/job/28500580680.
This commit is contained in:
Dean Herbert 2024-08-08 16:53:22 +09:00
parent 657da34f76
commit 03d543ec99
No known key found for this signature in database
1 changed files with 3 additions and 1 deletions

View File

@ -4,6 +4,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using osu.Framework.Allocation;
using osu.Framework.Audio;
using osu.Framework.Audio.Sample;
@ -455,6 +456,7 @@ public override void OnEntering(ScreenTransitionEvent e)
MultiplayerPlaylistItemStats[] stats = t.GetResultSafely();
var itemStats = stats.SingleOrDefault(item => item.PlaylistItemID == playlistItem.ID);
if (itemStats == null) return;
Schedule(() =>
@ -462,7 +464,7 @@ public override void OnEntering(ScreenTransitionEvent e)
breakdown.SetInitialCounts(itemStats.TotalScoreDistribution);
totals.SetInitialCounts(itemStats.TotalScoreDistribution.Sum(c => c), itemStats.CumulativeScore);
});
});
}, TaskContinuationOptions.OnlyOnRanToCompletion);
beatmapAvailabilityTracker.SelectedItem.Value = playlistItem;
beatmapAvailabilityTracker.Availability.BindValueChanged(_ => trySetDailyChallengeBeatmap(), true);