Use undefined instead of null.
This commit is contained in:
parent
0542b09e0f
commit
15c5beaecd
|
@ -112,7 +112,7 @@ function hideTopicVotes(data: HideVotesData, currentUser: string): number {
|
|||
(data.otherTopics && !postedBySelf) ||
|
||||
(data.ownTopics && postedBySelf)
|
||||
) {
|
||||
vote = topic.querySelector(".topic-voting-votes")!;
|
||||
vote = topic.querySelector(".topic-voting-votes") ?? undefined;
|
||||
}
|
||||
|
||||
if (vote !== undefined) {
|
||||
|
|
Loading…
Reference in New Issue