shouldRequestPermissionsAutomatically method
bool
shouldRequestPermissionsAutomatically({
- required bool autoRequestEnabled,
- PermissionStatus? currentStatus,
Determines if permissions should be requested automatically.
Implementation
bool shouldRequestPermissionsAutomatically({
required bool autoRequestEnabled,
PermissionStatus? currentStatus,
}) {
if (!autoRequestEnabled) return false;
return currentStatus != PermissionStatus.granted &&
currentStatus != PermissionStatus.permanentlyDenied;
}