isGranted property

Future<bool> get isGranted

Implementation

Future<bool> get isGranted async {
  if (permission == Permission.notification) {
    var permissionStatus = await status;
    return (permissionStatus == PermissionStatus.granted ||
        permissionStatus == PermissionStatus.limited);
  }
  return await permission.isGranted;
}