From 0099bf4aa548f272985ed22c6eff30f46b753193 Mon Sep 17 00:00:00 2001 From: andy840119 Date: Sun, 19 May 2024 23:19:10 +0800 Subject: [PATCH] Use quick way to fix this issue. DI object might be null in the dispose method. see: - https://github.com/ppy/osu/commit/b11ae1c5714b43d33ebbec569faf6569d0304c25 --- .../Screens/Edit/Beatmaps/Lyrics/LyricEditorVerifier.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorVerifier.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorVerifier.cs index 5c119bd68..7b1c81c6b 100644 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorVerifier.cs +++ b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Lyrics/LyricEditorVerifier.cs @@ -7,6 +7,7 @@ using osu.Framework.Allocation; using osu.Framework.Bindables; using osu.Framework.Caching; +using osu.Framework.Extensions.ObjectExtensions; using osu.Game.Beatmaps; using osu.Game.Rulesets.Edit; using osu.Game.Rulesets.Edit.Checks.Components; @@ -182,6 +183,10 @@ protected override void Dispose(bool isDisposing) { base.Dispose(isDisposing); + // todo: not very sure + if (!editorBeatmap.IsNull()) + return; + editorBeatmap.HitObjectAdded -= hitObjectAdded; editorBeatmap.HitObjectRemoved -= hitObjectRemoved; editorBeatmap.HitObjectUpdated -= hitObjectUpdated;