StatusCreateRequest.fromJson constructor

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

Implementation

factory StatusCreateRequest.fromJson(Map<String, Object?> json) {
  return StatusCreateRequest(
    scope: StatusScope.fromJson(
        json[r'scope'] as Map<String, Object?>? ?? const {}),
    statuses: (json[r'statuses'] as List<Object?>?)
            ?.map((i) =>
                StatusCreate.fromJson(i as Map<String, Object?>? ?? const {}))
            .toList() ??
        [],
  );
}