mirror of
https://github.com/ppy/osu
synced 2024-12-29 10:22:43 +00:00
Fix various test failures due to missing beatmap info in empty beatmap
This commit is contained in:
parent
58e84760b9
commit
a555407f37
@ -34,7 +34,7 @@ namespace osu.Game.Beatmaps
|
||||
protected override IBeatmap GetBeatmap()
|
||||
{
|
||||
if (BeatmapInfo.Path == null)
|
||||
return BeatmapInfo.Ruleset.CreateInstance().CreateBeatmapConverter(new Beatmap()).Beatmap;
|
||||
return BeatmapInfo?.Ruleset.CreateInstance().CreateBeatmapConverter(new Beatmap { BeatmapInfo = BeatmapInfo }).Beatmap;
|
||||
|
||||
try
|
||||
{
|
||||
|
@ -53,7 +53,7 @@ namespace osu.Game.Beatmaps
|
||||
{
|
||||
const double excess_length = 1000;
|
||||
|
||||
var lastObject = Beatmap.HitObjects.LastOrDefault();
|
||||
var lastObject = Beatmap?.HitObjects.LastOrDefault();
|
||||
|
||||
double length;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user