diff --git a/src/modules/processGitHubEvent.ts b/src/modules/processGitHubEvent.ts index 2db66a6..d53bcdd 100644 --- a/src/modules/processGitHubEvent.ts +++ b/src/modules/processGitHubEvent.ts @@ -44,7 +44,7 @@ export const processGithubEvent = async( } const { action } = request.body; await response.status(200).send({ message: "Payload received!" }); - if (action === "opened" && event === "issue" && isIssue(request.body)) { + if (action === "opened" && event === "issues" && isIssue(request.body)) { await logger.log("info", "Processing new issue"); const { issue, repository } = request.body; const { number } = issue; @@ -70,7 +70,5 @@ export const processGithubEvent = async( repo: name, reviewers: [ "naomi-lgbt" ], }); - return; } - await logger.log("warn", `Received ${event} ${String(action)} payload and do not know how to process.`); };