APlayer
APlayer copied to clipboard
InvalidStateError at IE or Edge
like this:

but when i run at chrome, it works correctly.
Same when i run ap.list.add()
This is caused by calling this.seek(0); in setAudio(audio) method : https://github.com/MoePlayer/APlayer/blob/103f6168770a7fcf380887f9b1291d3d947b1e66/src/js/player.js#L244
A solution would be to move the following code:
this.seek(0);
if (!this.paused) { this.audio.play(); }
inside the canplay event listener.