Hi,
When I press the home button and exit the app, streaming stops or I cannot hear.
How can I continue streaming in background and listen it from lock screen?
See this in stackoverflow
When I press the home button and exit the app, streaming stops or I cannot hear.
How can I continue streaming in background and listen it from lock screen?
See this in stackoverflow
stackoverflow:
do {
try AVAudioSession.sharedInstance().setCategory(.playback, mode: .default, options: [.mixWithOthers, .allowAirPlay])
print("Playback OK")
try AVAudioSession.sharedInstance().setActive(true)
print("Session is Active")
} catch {
print(error)
}