BulkPermissionGrants.fromJson constructor

BulkPermissionGrants.fromJson(
  1. Map<String, Object?> json
)

Implementation

factory BulkPermissionGrants.fromJson(Map<String, Object?> json) {
  return BulkPermissionGrants(
    globalPermissions: (json[r'globalPermissions'] as List<Object?>?)
            ?.map((i) => i as String? ?? '')
            .toList() ??
        [],
    projectPermissions: (json[r'projectPermissions'] as List<Object?>?)
            ?.map((i) => BulkProjectPermissionGrants.fromJson(
                i as Map<String, Object?>? ?? const {}))
            .toList() ??
        [],
  );
}