Fixed UI stuck indefinitely if READ_PHONE_STATE permission is denied on the dialer
This commit is contained in:
parent
ebaa6067b5
commit
4fd7246a74
1 changed files with 3 additions and 1 deletions
|
@ -218,8 +218,10 @@ class DialerFragment : SecureFragment<DialerFragmentBinding>() {
|
|||
if (grantResults.isNotEmpty() && grantResults[0] == PackageManager.PERMISSION_GRANTED) {
|
||||
Log.i("[Dialer] READ_PHONE_STATE permission has been granted")
|
||||
coreContext.initPhoneStateListener()
|
||||
// If first permission has been granted, continue to ask for permissions,
|
||||
// otherwise don't do it or it will loop indefinitely
|
||||
checkPermissions()
|
||||
}
|
||||
checkPermissions()
|
||||
} else if (requestCode == 1) {
|
||||
var allGranted = true
|
||||
for (result in grantResults) {
|
||||
|
|
Loading…
Reference in a new issue