The expo-av Playback class's unloadAsync method gives the following error: "TypeError: this._eventEmitter.removeSubscription is not a function" during unloadAsync function even though the unloading succeeds. Is there a way to avoid this error?
import {Audio} from 'expo-av';
...
useEffect(() => {
let soundHandler;
new Audio.Sound.createAsync(
require('../assets/test.mp3'), {shouldPlay: true, isLooping: true}
).then(({sound, status}) => {
soundHandler = sound;
});
return () => {
soundHandler.unloadAsync().catch(err=>{
console.log("Unload warning: " + err)
});
};
}, []);
...
Thanks in advance...