Minor code improvements
This commit is contained in:
@@ -591,8 +591,8 @@ class BaresipService: Service() {
|
|||||||
Log.d(TAG, "got uaEvent $event/$aor/$callp")
|
Log.d(TAG, "got uaEvent $event/$aor/$callp")
|
||||||
|
|
||||||
val call = Call.ofCallp(callp)
|
val call = Call.ofCallp(callp)
|
||||||
if (call == null && callp != 0L && ev[0] != "call incoming" && ev[0] != "call rejected" &&
|
if (call == null && callp != 0L &&
|
||||||
ev[0] != "call closed") {
|
!setOf("call incoming", "call rejected", "call closed").contains(ev[0])) {
|
||||||
Log.w(TAG, "uaEvent $event did not find call $callp")
|
Log.w(TAG, "uaEvent $event did not find call $callp")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@@ -954,8 +954,7 @@ class BaresipService: Service() {
|
|||||||
if (reason[0].isDigit())
|
if (reason[0].isDigit())
|
||||||
toast("${getString(R.string.call_failed)}: $reason")
|
toast("${getString(R.string.call_failed)}: $reason")
|
||||||
else
|
else
|
||||||
toast("${getString(R.string.call_closed)}: " +
|
toast("${getString(R.string.call_closed)}: ${Api.call_peer_uri(callp)}: $reason")
|
||||||
"$reason ${Api.call_peer_uri(callp)}")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user