1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-24 18:20:12 +08:00

Add ToList

This commit is contained in:
Dean Herbert
2018-07-20 16:38:02 +09:00
committed by GitHub
Unverified
parent 92fe996a8b
commit 7fea2b3a8b
+1 -1
View File
@@ -123,7 +123,7 @@ namespace osu.Game.Beatmaps
private void validateOnlineIds(List<BeatmapInfo> beatmaps)
{
var beatmapIds = beatmaps.Where(b => b.OnlineBeatmapID.HasValue).Select(b => b.OnlineBeatmapID);
var beatmapIds = beatmaps.Where(b => b.OnlineBeatmapID.HasValue).Select(b => b.OnlineBeatmapID).ToList();
// ensure all IDs are unique in this set and none match existing IDs in the local beatmap store.
if (beatmapIds.GroupBy(b => b).Any(g => g.Count() > 1) || QueryBeatmaps(b => beatmapIds.Contains(b.OnlineBeatmapID)).Any())