mirror of
https://github.com/SimpleMobileTools/Simple-Dialer.git
synced 2025-06-05 21:49:23 +02:00
minor style update
This commit is contained in:
@ -11,12 +11,10 @@ private val OUTGOING_CALL_STATES = arrayOf(STATE_CONNECTING, STATE_DIALING, STAT
|
||||
|
||||
@Suppress("DEPRECATION")
|
||||
fun Call?.getStateCompat(): Int {
|
||||
return if (this == null) {
|
||||
Call.STATE_DISCONNECTED
|
||||
} else if (isSPlus()) {
|
||||
details.state
|
||||
} else {
|
||||
state
|
||||
return when {
|
||||
this == null -> Call.STATE_DISCONNECTED
|
||||
isSPlus() -> details.state
|
||||
else -> state
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user