mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-17 11:28:06 +00:00
Log custom or unexpected types when parsing phone number labels
This commit is contained in:
parent
317bbb470b
commit
4a75315240
1 changed files with 12 additions and 2 deletions
|
|
@ -68,8 +68,18 @@ class PhoneNumberUtils {
|
|||
ContactsContract.CommonDataKinds.Phone.TYPE_WORK -> "work"
|
||||
ContactsContract.CommonDataKinds.Phone.TYPE_WORK_MOBILE -> "work,cell"
|
||||
ContactsContract.CommonDataKinds.Phone.TYPE_WORK_PAGER -> "work,pager"
|
||||
ContactsContract.CommonDataKinds.BaseTypes.TYPE_CUSTOM -> default ?: "custom"
|
||||
else -> default ?: type.toString()
|
||||
ContactsContract.CommonDataKinds.BaseTypes.TYPE_CUSTOM -> {
|
||||
Log.i(
|
||||
"$TAG Found custom phone label type using default value [$default] or 'custom' if null"
|
||||
)
|
||||
default ?: "custom"
|
||||
}
|
||||
else -> {
|
||||
Log.w(
|
||||
"$TAG Can't translate phone label type [$type], using default value [$default]"
|
||||
)
|
||||
default ?: type.toString()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue