mirror of
https://github.com/SimpleMobileTools/Simple-Flashlight.git
synced 2025-02-16 20:00:40 +01:00
Inline handlePermissionResult
This commit is contained in:
parent
dabdfdcd7d
commit
e190cac2a3
@ -336,11 +336,7 @@ class MainActivity : ComponentActivity() {
|
||||
}
|
||||
}
|
||||
|
||||
private fun getPermissionResultHandler(isSos: Boolean): (Boolean) -> Unit = {
|
||||
handlePermissionResult(isSos, it)
|
||||
}
|
||||
|
||||
private fun handlePermissionResult(isSos: Boolean, granted: Boolean) {
|
||||
private fun getPermissionResultHandler(isSos: Boolean): (Boolean) -> Unit = { granted ->
|
||||
if (granted) {
|
||||
cameraPermissionGranted(isSos)
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user