Removed comments
This commit is contained in:
@@ -58,13 +58,10 @@ class ConnectionService : ConnectionService() {
|
|||||||
|
|
||||||
val ua = UserAgent.ofUap(uap)
|
val ua = UserAgent.ofUap(uap)
|
||||||
if (ua != null) {
|
if (ua != null) {
|
||||||
// Check speakerphone setting
|
|
||||||
if (BaresipService.speakerPhone) {
|
if (BaresipService.speakerPhone) {
|
||||||
@Suppress("DEPRECATION")
|
@Suppress("DEPRECATION")
|
||||||
connection.setAudioRoute(CallAudioState.ROUTE_SPEAKER)
|
connection.setAudioRoute(CallAudioState.ROUTE_SPEAKER)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for Auto-Answer
|
|
||||||
if (ua.account.answerMode == Api.ANSWERMODE_AUTO) {
|
if (ua.account.answerMode == Api.ANSWERMODE_AUTO) {
|
||||||
Log.d(TAG, "Auto-answering call $callp")
|
Log.d(TAG, "Auto-answering call $callp")
|
||||||
connection.onAnswer()
|
connection.onAnswer()
|
||||||
@@ -90,7 +87,6 @@ class ConnectionService : ConnectionService() {
|
|||||||
val rootExtras = request?.extras
|
val rootExtras = request?.extras
|
||||||
val nestedExtras = rootExtras?.getBundle(TelecomManager.EXTRA_OUTGOING_CALL_EXTRAS)
|
val nestedExtras = rootExtras?.getBundle(TelecomManager.EXTRA_OUTGOING_CALL_EXTRAS)
|
||||||
|
|
||||||
// Try root extras first, then fallback to nested
|
|
||||||
val uap = rootExtras?.getLong("uap", 0L).takeIf { it != 0L }
|
val uap = rootExtras?.getLong("uap", 0L).takeIf { it != 0L }
|
||||||
?: nestedExtras?.getLong("uap") ?: 0L
|
?: nestedExtras?.getLong("uap") ?: 0L
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user