Skip to content

Commit

Permalink
used includes instead
Browse files Browse the repository at this point in the history
  • Loading branch information
JSLegendDev committed Jan 1, 2024
1 parent 252e349 commit 2a26a5d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
<script>
// prevent itch.io scrolling
window.addEventListener("keydown", function (e) {
if ([32, 37, 38, 39, 40].indexOf(e.keyCode) > -1) {
if ([32, 37, 38, 39, 40].includes(e.keyCode)) {
e.preventDefault();
}
});
Expand Down

0 comments on commit 2a26a5d

Please sign in to comment.