ClimateProductOrId.fromJson constructor

ClimateProductOrId.fromJson(
  1. Object? json
)

Implementation

factory ClimateProductOrId.fromJson(Object? json) {
  if (json is String) {
    return ClimateProductId(id: json);
  }
  return ClimateProduct.fromJson(json);
}