Skip to content

Commit 74c03e7

Browse files
committed
fix(player): create AudioContext before resuming so first click plays
handlePlay called resumeAudio() before connectAudio(), but at that point the module-level ctx in lib/audio.ts is still null — resumeAudio returned Promise.resolve() and the gesture window was wasted on a no-op. connectAudio() then created a fresh AudioContext in suspended state, audio routed through its destination stayed silent, and the listener had to click play a second time to get sound. Reorder to: connectAudio (creates the context), resumeAudio (resumes inside the same gesture), then el.play().
1 parent 3acd51c commit 74c03e7

4 files changed

Lines changed: 17 additions & 15 deletions

File tree

server/frontend/dist/assets/player-8U0MVQ3P.js

Lines changed: 0 additions & 9 deletions
This file was deleted.

0 commit comments

Comments
 (0)