teodorpatras / Jukebox

Player for streaming local and remote audio files. Written in Swift.
MIT License
552 stars 122 forks source link

Problem with Siri #74

Open lucabecchetti opened 7 years ago

lucabecchetti commented 7 years ago

Hi, i have last version, we have a problem when using siri to write a text in a textarea, when siri complete text recognition, resumePlayback() is called, and this line:

currentItem!.refreshPlayerItem(withAsset: currentItem!.playerItem!.asset)

cause a crash, I think we have to insert this code on top of function:

if currentItem == nil{ return }

jessejohnson commented 6 years ago

I just experienced this bug. I'm forking the project with @lucabecchetti 's snippet (which works!). This fix is extremely urgent. Thanks.

edit: @lucabecchetti This issue should be retitled to be more accurate. The LOC you indicated crashes when Jukebox tries to resume playback after is has been interrupted. Thanks!