holgerkrupp / onetrickpony

Single Purpose Podcast App for iOS - written in swift
6 stars 2 forks source link

App crashing when trying to stream episodes #1

Closed holgerkrupp closed 8 years ago

holgerkrupp commented 8 years ago

When switching to the Player view, the usage of the Play controls will crash the App

holgerkrupp commented 8 years ago

Explination: AudioPlayer uses AVAudioPlayer. AVAudioPlayer does not support Streaming. When the file is not locally, I don't initialize the player. When the Play controls are used, they try to access a non existing player and crash.

Solution: Enable Streaming by initializing AVPlayer when file is not locally. QuickFix: Disable Playbuttons (or the Episode Player View) when the file is not locally.

holgerkrupp commented 8 years ago

replaced AVAudioPlayer with AVPlayer