From d73a179f590e3526f5cd5a0b20d7f0768904dc32 Mon Sep 17 00:00:00 2001 From: the-djmaze <> Date: Tue, 19 Jul 2022 11:50:57 +0200 Subject: [PATCH] Unregister audio initialization event listeners first --- dev/Common/Audio.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/Common/Audio.js b/dev/Common/Audio.js index befd17491..4d7d5a862 100644 --- a/dev/Common/Audio.js +++ b/dev/Common/Audio.js @@ -46,11 +46,11 @@ let notificator = null, 'keydown','keyup' ], unlock = () => { + unlockEvents.forEach(type => doc.removeEventListener(type, unlock, true)); if (audioCtx) { console.log('AudioContext ' + audioCtx.state); audioCtx.resume(); } - unlockEvents.forEach(type => doc.removeEventListener(type, unlock, true)); // setTimeout(()=>SMAudio.playNotification(0,1),1); };