RestrictionInfo.fromJson constructor Null safety

RestrictionInfo.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory RestrictionInfo.fromJson(Map<String, dynamic> json) {
  json['end_at'] = json['end_at'] ?? json['muted_end_at'];
  json['start_at'] = json['start_at'] ?? json['muted_start_at'];
  json['description'] = json['description'] ?? json['muted_description'];
  if (json['type'] == null) json['type'] = 'muted';
  return _$RestrictionInfoFromJson(json);
}