From 68a359698d114c8eac351c393ef408001d78140c Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Thu, 2 Mar 2017 18:35:24 +0900 Subject: [PATCH] Fix potential nullref caused by test data. --- osu.Game/Database/BeatmapInfo.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osu.Game/Database/BeatmapInfo.cs b/osu.Game/Database/BeatmapInfo.cs index 7a976a1f7a..1c2ae2bf78 100644 --- a/osu.Game/Database/BeatmapInfo.cs +++ b/osu.Game/Database/BeatmapInfo.cs @@ -88,7 +88,7 @@ namespace osu.Game.Database return ID == other?.ID; } - public bool AudioEquals(BeatmapInfo other) => other != null && + public bool AudioEquals(BeatmapInfo other) => other != null && BeatmapSet != null && other.BeatmapSet != null && BeatmapSet.Path == other.BeatmapSet.Path && (Metadata ?? BeatmapSet.Metadata).AudioFile == (other.Metadata ?? other.BeatmapSet.Metadata).AudioFile; }