onPollVoteRemoved method

void onPollVoteRemoved(
  1. String voteId
)

Handles the removal of a poll vote.

Implementation

void onPollVoteRemoved(String voteId) {
  final updatedVotes = state.votes.where((it) {
    return it.id != voteId;
  }).toList();

  state = state.copyWith(votes: updatedVotes);
}