1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-19 20:20:21 +08:00

Add assert on storing to database

This commit is contained in:
Dean Herbert
2021-05-24 18:41:39 +09:00
Unverified
parent deabce7140
commit a00f226ab3
+2 -2
View File
@@ -3,6 +3,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using osu.Framework.Input.Bindings;
using osu.Framework.Platform;
@@ -105,8 +106,7 @@ namespace osu.Game.Input
{
var dbKeyBinding = (DatabasedKeyBinding)keyBinding;
if (dbKeyBinding.RulesetID != null && !CheckValidForGameplay(keyBinding.KeyCombination))
return;
Debug.Assert(dbKeyBinding.RulesetID == null || CheckValidForGameplay(keyBinding.KeyCombination));
Refresh(ref dbKeyBinding);