mirror of
https://github.com/osukey/osukey.git
synced 2025-06-16 16:57:56 +09:00
Disallow updating the database to an invalid value
This commit is contained in:
parent
57640810b5
commit
deabce7140
@ -104,6 +104,10 @@ namespace osu.Game.Input
|
|||||||
using (ContextFactory.GetForWrite())
|
using (ContextFactory.GetForWrite())
|
||||||
{
|
{
|
||||||
var dbKeyBinding = (DatabasedKeyBinding)keyBinding;
|
var dbKeyBinding = (DatabasedKeyBinding)keyBinding;
|
||||||
|
|
||||||
|
if (dbKeyBinding.RulesetID != null && !CheckValidForGameplay(keyBinding.KeyCombination))
|
||||||
|
return;
|
||||||
|
|
||||||
Refresh(ref dbKeyBinding);
|
Refresh(ref dbKeyBinding);
|
||||||
|
|
||||||
if (dbKeyBinding.KeyCombination.Equals(keyBinding.KeyCombination))
|
if (dbKeyBinding.KeyCombination.Equals(keyBinding.KeyCombination))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user