ReviewOrId.fromJson constructor

ReviewOrId.fromJson(
  1. Object? json
)

Implementation

factory ReviewOrId.fromJson(Object? json) {
  if (json is String) {
    return ReviewId(id: json);
  }
  return Review.fromJson(json);
}