|
|
@ -201,7 +201,7 @@ protocol CallAudioServiceDelegate: class {
|
|
|
|
|
|
|
|
|
|
|
|
private func updateIsSpeakerphoneEnabled() {
|
|
|
|
private func updateIsSpeakerphoneEnabled() {
|
|
|
|
let value = avAudioSession.currentRoute.outputs.contains { (portDescription: AVAudioSessionPortDescription) -> Bool in
|
|
|
|
let value = avAudioSession.currentRoute.outputs.contains { (portDescription: AVAudioSessionPortDescription) -> Bool in
|
|
|
|
return portDescription.portName == .builtInSpeaker
|
|
|
|
return portDescription.portType == .builtInSpeaker
|
|
|
|
}
|
|
|
|
}
|
|
|
|
DispatchQueue.main.async {
|
|
|
|
DispatchQueue.main.async {
|
|
|
|
self.isSpeakerphoneEnabled = value
|
|
|
|
self.isSpeakerphoneEnabled = value
|
|
|
|