We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a608c79 commit 5de0f8aCopy full SHA for 5de0f8a
apps/client/src/routes/room.$roomId/vote.$userId.$votingKey.tsx
@@ -99,10 +99,10 @@ function SingleQuestionVoting({ data }: { data: QuestionVotingData }) {
99
control={control}
100
render={({ field: { value, onChange } }) => (
101
<>
102
- {candidatesReordered.map((candidate) => (
+ {candidatesReordered.filter(Boolean).map((candidate) => (
103
<Button
104
className={twMerge(
105
- value === candidate.id ? "btn-accent" : undefined,
+ value === candidate?.id ? "btn-accent" : undefined,
106
)}
107
onClick={() => {
108
onChange(candidate.id);
0 commit comments