diff --git a/src/components/AudioPlayer.tsx b/src/components/AudioPlayer.tsx index e4082cf..b83ca82 100644 --- a/src/components/AudioPlayer.tsx +++ b/src/components/AudioPlayer.tsx @@ -59,6 +59,11 @@ export const AudioPlayer: React.FC = ({ const [coefficient, setCoefficient] = useState(0); const [hasError, setHasError] = useState(false); + useEffect(() => { + handleReload(); + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [src]); + useEffect(() => { if (!isNaN(volume)) { const tempVol = volume > 100 ? 100 : volume < 0 ? 0 : volume;