From b6b4f0e5a1b34bbbaa98f7dcaa9394f269b0c7a4 Mon Sep 17 00:00:00 2001 From: Mentlegen <9807008+gentlementlegen@users.noreply.github.com> Date: Sun, 18 Aug 2024 18:37:39 +0900 Subject: [PATCH] chore: added OWNER as a collborator status --- src/helpers/github.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/helpers/github.ts b/src/helpers/github.ts index c20322e1..c079e95f 100644 --- a/src/helpers/github.ts +++ b/src/helpers/github.ts @@ -32,7 +32,7 @@ export async function getMergeTimeoutAndApprovalRequiredCount(context: Context, mergeTimeout: context.config.mergeTimeout.contributor, requiredApprovalCount: context.config.approvalsRequired.contributor, }; - return authorAssociation === "COLLABORATOR" || authorAssociation === "MEMBER" ? timeoutCollaborator : timeoutContributor; + return ["COLLABORATOR", "MEMBER", "OWNER"].includes(authorAssociation) ? timeoutCollaborator : timeoutContributor; } export async function getApprovalCount({ octokit, logger }: Context, { owner, repo, issue_number: pullNumber }: IssueParams) { @@ -151,7 +151,7 @@ export async function getOpenPullRequests(context: Context, targets: ReposWatchS } export async function mergePullRequest(context: Context, { repo, owner, issue_number: pullNumber }: IssueParams) { - await context.octokit.pulls.merge({ + await context.octokit.rest.pulls.merge({ owner, repo, pull_number: pullNumber,