From 2e90c74e62865dc2509f8cf576d8b266b5b7fb93 Mon Sep 17 00:00:00 2001 From: Anmol Baranwal Date: Mon, 16 Oct 2023 23:09:35 +0530 Subject: [PATCH] chore: remove default values and correct logic --- action.yml | 4 +--- index.ts | 4 ++-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/action.yml b/action.yml index 8f5671f..02efb21 100644 --- a/action.yml +++ b/action.yml @@ -7,13 +7,11 @@ inputs: default: "up for grabs" issueNumber: description: "Include the previous issue number created by the author in the comment." - default: "false" comment: description: "Custom text to add with or without the issue number in the comment." - default: "false" + default: "" close: description: "Close the current issue if set to true." - default: "true" runs: using: "node20" main: "index.ts" diff --git a/index.ts b/index.ts index 00858a2..2af1871 100644 --- a/index.ts +++ b/index.ts @@ -25,9 +25,9 @@ async function HandleMultipleIssues() { // Retrieve custom inputs const label = core.getInput("label") || "up for grabs"; // Set default label - const issueNumber = core.getInput("issueNumber") === "true"; // converts to boolean + const issueNumber = core.getInput("issueNumber") === "true" || false; // converts to boolean const comment = core.getInput("comment"); - const close = core.getInput("close") === "true"; + const close = core.getInput("close") === "true" || false; const checkComment = comment.trim() !== "";