From 1534b75d27658a3bc671a3a483f276bc49e67766 Mon Sep 17 00:00:00 2001 From: Joehu Date: Thu, 4 Jul 2019 21:39:21 -0700 Subject: [PATCH] Fix ci errors --- .../Visual/SongSelect/TestSceneLeaderboard.cs | 11 ----------- .../Screens/Select/Leaderboards/BeatmapLeaderboard.cs | 6 ++++++ 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/osu.Game.Tests/Visual/SongSelect/TestSceneLeaderboard.cs b/osu.Game.Tests/Visual/SongSelect/TestSceneLeaderboard.cs index fc42048984..f6164c8a73 100644 --- a/osu.Game.Tests/Visual/SongSelect/TestSceneLeaderboard.cs +++ b/osu.Game.Tests/Visual/SongSelect/TestSceneLeaderboard.cs @@ -4,12 +4,9 @@ using System; using System.Collections.Generic; using System.ComponentModel; -using System.Linq; -using osu.Framework.Allocation; using osu.Framework.Graphics; using osu.Game.Beatmaps; using osu.Game.Online.Leaderboards; -using osu.Game.Rulesets; using osu.Game.Scoring; using osu.Game.Screens.Select.Leaderboards; using osu.Game.Users; @@ -27,8 +24,6 @@ namespace osu.Game.Tests.Visual.SongSelect typeof(RetrievalFailurePlaceholder), }; - private RulesetStore rulesets; - private readonly FailableLeaderboard leaderboard; public TestSceneLeaderboard() @@ -57,12 +52,6 @@ namespace osu.Game.Tests.Visual.SongSelect AddStep(@"Unpublished beatmap", unpublishedBeatmap); } - [BackgroundDependencyLoader] - private void load(RulesetStore rulesets) - { - this.rulesets = rulesets; - } - private void newScores() { var scores = new[] diff --git a/osu.Game/Screens/Select/Leaderboards/BeatmapLeaderboard.cs b/osu.Game/Screens/Select/Leaderboards/BeatmapLeaderboard.cs index 34f46608da..550e87bcdc 100644 --- a/osu.Game/Screens/Select/Leaderboards/BeatmapLeaderboard.cs +++ b/osu.Game/Screens/Select/Leaderboards/BeatmapLeaderboard.cs @@ -68,6 +68,12 @@ namespace osu.Game.Screens.Select.Leaderboards return null; } + if (Beatmap?.OnlineBeatmapID == null) + { + PlaceholderState = PlaceholderState.Unavailable; + return null; + } + switch (Beatmap?.Status) { case BeatmapSetOnlineStatus.Graveyard: