diff --git a/replay.pokemonshowdown.com/src/replays-battle.tsx b/replay.pokemonshowdown.com/src/replays-battle.tsx index 8871bf8229..91f024188c 100644 --- a/replay.pokemonshowdown.com/src/replays-battle.tsx +++ b/replay.pokemonshowdown.com/src/replays-battle.tsx @@ -168,7 +168,7 @@ export class BattlePanel extends preact.Component<{id: string}> { } // @ts-ignore if (e.target?.tagName === 'INPUT' || e.target?.tagName === 'SELECT') return; - let target; + let target; switch (e.keyCode) { case 75: // k if (this.battle?.atQueueEnd) { @@ -232,26 +232,26 @@ export class BattlePanel extends preact.Component<{id: string}> { this.changeSpeed({target}); break; case 70: // f - target = this.base?.querySelector('select[name=speed]'); - if (!target) return; + target = this.base?.querySelector('select[name=speed]'); + if (!target) return; target.value = 'fast'; this.changeSpeed({target}); break; case 78: // n target = this.base?.querySelector('select[name=speed]'); - if (!target) return; + if (!target) return; target.value = 'normal'; this.changeSpeed({target}); break; case 83: // s target = this.base?.querySelector('select[name=speed]'); - if (!target) return; + if (!target) return; target.value = 'slow'; this.changeSpeed({target}); break; case 82: // r target = this.base?.querySelector('select[name=speed]'); - if (!target) return; + if (!target) return; target.value = 'reallyslow'; this.changeSpeed({target}); break;