Mention user that is being detected for duplicate vote

This commit is contained in:
Sebastian Cabrera 2023-08-29 09:37:59 -04:00
parent d8d5f2e9e2
commit ce25b3c9f9

View file

@ -147,9 +147,12 @@ func processIssueCommentEvent(event *github.IssueCommentEvent) {
reactionCount++
approvals[prNumber] = commentAuthor
} else {
commentText := "@(#{commentAuthor}) your vote has already been counted :x:"
commentText = strings.Replace(commentText, "(#{commentAuthor})", commentAuthor, 1)
// Respond with a comment
comment := &github.IssueComment{
Body: github.String("Your vote has already been counted :x:"),
Body: github.String(commentText),
}
_, _, err := client.Issues.CreateComment(ctx, owner, repo, prNumber, comment)