diff --git a/app/src/main/kotlin/com/tutpro/baresip/BaresipService.kt b/app/src/main/kotlin/com/tutpro/baresip/BaresipService.kt index b56bcf04..3badfc8b 100644 --- a/app/src/main/kotlin/com/tutpro/baresip/BaresipService.kt +++ b/app/src/main/kotlin/com/tutpro/baresip/BaresipService.kt @@ -1107,14 +1107,13 @@ class BaresipService: Service() { } private fun stopRinging() { - if (am.mode == AudioManager.MODE_RINGTONE) { + if (am.mode == AudioManager.MODE_RINGTONE) abandonAudioFocus() - if ((VERSION.SDK_INT < 28) && (rtTimer != null)) { - rtTimer!!.cancel() - rtTimer = null - } - rt.stop() + if ((VERSION.SDK_INT < 28) && (rtTimer != null)) { + rtTimer!!.cancel() + rtTimer = null } + rt.stop() } private fun setCallVolume() {