toJson method
Implementation
@override
Map<String, dynamic> toJson() => <String, dynamic>{
'id': id,
'text': text?.toJson(),
'media': media?.toJson(),
'voter_count': voterCount,
'vote_percentage': votePercentage,
'recent_voter_ids': recentVoterIds.map((item) => item.toJson()).toList(),
'is_chosen': isChosen,
'is_being_chosen': isBeingChosen,
'author': author?.toJson(),
'addition_date': additionDate,
'@type': constructor,
};