From 6334194590a3f31ad3fe2f2fb7c9b83caf70f84c Mon Sep 17 00:00:00 2001 From: okseby Date: Wed, 30 Aug 2023 20:40:56 -0400 Subject: [PATCH 1/2] version bump --- bot/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot/main.go b/bot/main.go index 2f0dd0f..d9e763b 100644 --- a/bot/main.go +++ b/bot/main.go @@ -1,6 +1,6 @@ package main -var version = "v0.05" +var version = "v0.06" func main() { initGitHubClient(version) From 08006bf0eaf75811658b79b4b90e60c45eb062e8 Mon Sep 17 00:00:00 2001 From: okseby Date: Wed, 30 Aug 2023 20:46:58 -0400 Subject: [PATCH 2/2] Revert strict emoji checking as I think it broke something --- bot/utils.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bot/utils.go b/bot/utils.go index 68cfa95..180d1c1 100644 --- a/bot/utils.go +++ b/bot/utils.go @@ -88,7 +88,7 @@ func webhookHandler(w http.ResponseWriter, r *http.Request) { log.Println("User type:", userType, "Comment body:", commentBody) - if !strings.Contains(userType, "bot") && strings.Contains(commentBody, ":+1:") { + if !strings.Contains(userType, "bot") && strings.Contains(commentBody, "+1") { log.Println("Received Issue Comment Event: processing now!") processIssueCommentEvent(event) break @@ -147,7 +147,7 @@ func processIssueCommentEvent(event *github.IssueCommentEvent) { commentAuthor := comment.GetUser().GetLogin() commentBody := comment.GetBody() - if !strings.Contains(userType, "bot") && strings.Contains(commentBody, ":+1:") { + if !strings.Contains(userType, "bot") && strings.Contains(commentBody, "+1") { _, exists := approvals[commentAuthor] if !exists { approvals[commentAuthor] = 1