File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -153,12 +153,15 @@ const Upload = (props) => {
153
153
let newChanged = { ...changed } ;
154
154
for ( let [ uuid , ] of Object . entries ( newKeybinds ) ) {
155
155
// If key is provided, also update all keycodes
156
- let keycode = 0 ;
157
156
if ( key ) {
158
- keycode = parseInt ( Utils . findKeyByValue ( simpleKeyboardKeyNames , key . toLowerCase ( ) ) ) ;
157
+ let keycode = parseInt ( Utils . findKeyByValue ( simpleKeyboardKeyNames , key . toLowerCase ( ) ) ) ;
158
+ newHotkeys [ uuid ] . keycode = keycode ;
159
+ newKeybinds [ uuid ] . keycode = keycode ;
160
+ }
161
+ else if ( key === 0 ) {
162
+ newHotkeys [ uuid ] . keycode = key ;
163
+ newKeybinds [ uuid ] . keycode = key ;
159
164
}
160
- newKeybinds [ uuid ] . keycode = keycode ;
161
- newHotkeys [ uuid ] . keycode = keycode ;
162
165
163
166
// Since datasets from rows don't include menu_id or string_id, we have to
164
167
// make sure to copy them over "manually"
You can’t perform that action at this time.
0 commit comments