mirror of
https://github.com/ppy/osu.git
synced 2026-06-07 05:43:41 +08:00
Fix sample set index entry box crashing on bad input (#36390)
closes https://github.com/ppy/osu/issues/36374
This commit is contained in:
committed by
GitHub
Unverified
parent
e62a01cf77
commit
c1d9de7e83
@@ -120,7 +120,8 @@ namespace osu.Game.Screens.Edit.Setup
|
||||
};
|
||||
numberBox.OnCommit += (_, _) =>
|
||||
{
|
||||
committedIndex = int.Parse(numberBox.Current.Value);
|
||||
if (int.TryParse(numberBox.Current.Value, out int parsed))
|
||||
committedIndex = parsed;
|
||||
Hide();
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user