From d508e625393839becbbd467cb895858477d92482 Mon Sep 17 00:00:00 2001 From: pngwn Date: Wed, 31 Jan 2024 18:40:35 +0000 Subject: [PATCH] fix --- packages/find-pr/index.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/find-pr/index.ts b/packages/find-pr/index.ts index 5053cb3..a6ada83 100644 --- a/packages/find-pr/index.ts +++ b/packages/find-pr/index.ts @@ -65,6 +65,7 @@ async function run() { outputs.mergeable = mergeable === "MERGEABLE" ? true : false; outputs.merge_sha = merge_sha || sha || false; } else if (context.eventName === "pull_request") { + console.log("PULL REQUEST", JSON.stringify(context.payload.pull_request)); const source_repo = context.payload.pull_request?.head.repo.full_name; const source_branch = context.payload.pull_request?.head.ref; const pr_number = context.payload.pull_request?.number; @@ -74,7 +75,7 @@ async function run() { outputs.pr_number = pr_number ?? false; outputs.sha = context.payload.pull_request?.head.sha || false; outputs.found_pr = !!(source_repo && source_branch && pr_number); - outputs.mergeable = context.payload.pull_request?.mergeable === true; + outputs.mergeable = context.payload.pull_request?.mergeable === "MERGEABLE"; outputs.merge_sha = context.payload.pull_request?.merge_commit_sha || outputs.sha || false; } else if (context.eventName === "issue_comment") {