import 'package:permissions/permissions.dart';
// ...
Future<void> getAuthorizationStatus() async {
Permissions _permissions = Permissions();
final status = await _permissions.location.getPermissionStatus();
print("Current status? ${status}");
if (status == LocationPermissionStatus.pending) {
final newStatus = await permissions.location.requestAlwaysPermission();
print("New status? ${newStatus}");
}
}
getAuthorizationStatus();
-
Notifications
You must be signed in to change notification settings - Fork 0
License
UnlockAgency/flutter_location_permissions
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
License
Stars
Watchers
Forks
Packages 0
No packages published