fromJson static method

GiveawayInfoOngoing? fromJson(
  1. Map<String, dynamic>? json
)
override

Implementation

static GiveawayInfoOngoing? fromJson(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }

  return GiveawayInfoOngoing(
    creationDate: (json['creation_date'] as int?) ?? 0,
    status: GiveawayParticipantStatus.fromJson(tdMapFromJson(json['status'])),
    isEnded: (json['is_ended'] as bool?) ?? false,
  );
}