PollOption.fromJSON constructor

PollOption.fromJSON(
  1. Map<String, dynamic> json
)

Implementation

PollOption.fromJSON(Map<String, dynamic> json)
    : optionId = json['optionId'],
      text = json['text'],
      attachment = json['attachment'] == null
          ? null
          : MediaAttachment.fromJSON(json['attachment']),
      voteCount = json['voteCount'],
      isVotedByMe = json['isVotedByMe'];