mirror of
https://github.com/osukey/osukey.git
synced 2025-08-07 00:23:59 +09:00
Avoid potential crashes when lease is held on SelectedMods
This commit is contained in:
@ -469,6 +469,10 @@ namespace osu.Game
|
|||||||
{
|
{
|
||||||
updateModDefaults();
|
updateModDefaults();
|
||||||
|
|
||||||
|
// a lease may be taken on the mods bindable, at which point we can't really ensure valid mods.
|
||||||
|
if (SelectedMods.Disabled)
|
||||||
|
return;
|
||||||
|
|
||||||
if (!ModUtils.CheckValidForGameplay(mods.NewValue, out var invalid))
|
if (!ModUtils.CheckValidForGameplay(mods.NewValue, out var invalid))
|
||||||
{
|
{
|
||||||
// ensure we always have a valid set of mods.
|
// ensure we always have a valid set of mods.
|
||||||
|
Reference in New Issue
Block a user