mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 15:33:05 +08:00
Merge pull request #4136 from Aergwyn/fix-tracked-config-disposal
Fix crash when config doesn't have track-able settings
This commit is contained in:
commit
7f8da819a0
@ -161,7 +161,7 @@ namespace osu.Game.Overlays
|
|||||||
if (configManager == null) throw new ArgumentNullException(nameof(configManager));
|
if (configManager == null) throw new ArgumentNullException(nameof(configManager));
|
||||||
|
|
||||||
if (!trackedConfigManagers.TryGetValue((source, configManager), out var existing))
|
if (!trackedConfigManagers.TryGetValue((source, configManager), out var existing))
|
||||||
throw new InvalidOperationException($"{nameof(configManager)} is not registered.");
|
return;
|
||||||
|
|
||||||
existing.Unload();
|
existing.Unload();
|
||||||
existing.SettingChanged -= display;
|
existing.SettingChanged -= display;
|
||||||
|
Loading…
Reference in New Issue
Block a user