From 1900d9dd313c7c1e39448e531724ec2b0a41544a Mon Sep 17 00:00:00 2001 From: Richard Guo Date: Thu, 18 May 2023 13:17:31 -0400 Subject: [PATCH] Update close_issues.yml (#629) Signed-off-by: Richard Guo --- .github/workflows/close_issues.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/close_issues.yml b/.github/workflows/close_issues.yml index 5f476f87..fef045d2 100644 --- a/.github/workflows/close_issues.yml +++ b/.github/workflows/close_issues.yml @@ -19,8 +19,8 @@ jobs: for (let { number } of issues.data) { const issueData = await github.issues.get({...repo, issue_number: number}); const comments = await github.issues.listComments({...repo, issue_number: number}); - if (issueData.data.labels.length === 0 && comments.data.length < 1) { + if (issueData.data.labels.length === 0 && comments.data.length <= 1) { await github.issues.update({...repo, issue_number: number, state: 'closed'}); await github.issues.createComment({...repo, issue_number: number, body: 'Issue closed as it does not have any labels or comments.'}); } - } \ No newline at end of file + }