Skip to content

Commit

Permalink
fix double sound
Browse files Browse the repository at this point in the history
  • Loading branch information
zachmolony committed Nov 30, 2023
1 parent 331e732 commit bd2beae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/components/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,11 @@ export function Layout({cart, children = null, header}: LayoutProps) {
playRandomSound();
};

window.addEventListener('click', handleClick);
// window.addEventListener('click', handleClick);
window.addEventListener('touchstart', handleClick);

return () => {
window.removeEventListener('click', handleClick);
// window.removeEventListener('click', handleClick);
window.removeEventListener('touchstart', handleClick);
};
}, []);
Expand Down

0 comments on commit bd2beae

Please sign in to comment.