Skip to content

Commit

Permalink
Update keyboard-util.js
Browse files Browse the repository at this point in the history
  • Loading branch information
cacheflowe committed Apr 27, 2024
1 parent f36e140 commit d9f8213
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/keyboard-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class KeyboardUtil {
window.addEventListener("keydown", (e) => {
let key = e.key;
if (key.length > 1) return; // ignore non alpha-numeric characters
charStream.push({ key: e.key, time: Date.now() });
charStream.push({ key: key, time: Date.now() });
charStream = charStream.filter((char) => {
return char.time > Date.now() - timeWindow;
});
Expand Down

0 comments on commit d9f8213

Please sign in to comment.