diff --git a/directory/src/routes/Error.jsx b/directory/src/routes/Error.jsx index 7577447..0ba1610 100644 --- a/directory/src/routes/Error.jsx +++ b/directory/src/routes/Error.jsx @@ -146,7 +146,12 @@ export default function Error() { } })) } - }, [playVoice, spineData]); + return () => { + if (spinePlayer) { + spinePlayer.dispose() + } + } + }, [playVoice, spineData, spinePlayer]); return (