decode the incoming call number before displaying
This commit is contained in:
parent
012442a057
commit
9e015c3888
1 changed files with 1 additions and 2 deletions
|
@ -14,12 +14,11 @@ import com.simplemobiletools.contacts.pro.objects.CallManager
|
|||
|
||||
@TargetApi(Build.VERSION_CODES.M)
|
||||
class MyIncomingCallService : InCallService() {
|
||||
|
||||
override fun onCallAdded(call: Call) {
|
||||
super.onCallAdded(call)
|
||||
call.registerCallback(callCallback)
|
||||
|
||||
val handle = call.details.handle.toString()
|
||||
val handle = Uri.decode(call.details.handle.toString())
|
||||
val callerNumber = if (handle.contains("tel:")) {
|
||||
handle.substringAfter("tel:")
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue