Commit baa81126 authored by missionfloyd's avatar missionfloyd

Move gamepaddisconnected listener

parent 679e8738
......@@ -24,7 +24,10 @@ window.addEventListener('gamepadconnected', (e) => {
isWaiting = false;
}
}, 10);
window.addEventListener('gamepaddisconnected', (e) => clearInterval(gamepads[e.gamepad.index]));
});
window.addEventListener('gamepaddisconnected', (e) => {
clearInterval(gamepads[e.gamepad.index]);
});
/*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment