From 5a9d1a0a333e36f33638e2581fa2beb4d9645bea Mon Sep 17 00:00:00 2001 From: Ji Sang Seo Date: Sun, 11 Feb 2024 15:18:30 +0900 Subject: [PATCH] fix: typos --- src/git.mjs | 2 +- src/task/pr.mjs | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/git.mjs b/src/git.mjs index c190506..6e79bf9 100644 --- a/src/git.mjs +++ b/src/git.mjs @@ -78,7 +78,7 @@ export async function fetch() { export async function merge(branch) { const mergeResult = git("merge", branch); - if (result.status !== 0) { + if (mergeResult.status !== 0) { throw new Error("Failed to merge"); } } diff --git a/src/task/pr.mjs b/src/task/pr.mjs index 9e0981b..cdd9dee 100644 --- a/src/task/pr.mjs +++ b/src/task/pr.mjs @@ -30,7 +30,7 @@ export async function pullRequest() { const currentBranchName = git.getCurrentBranchName(); const task = Object.values(taskCollection).find( - (task) => task.title === currentBranchName + (task) => git.toBranchName(task.title) === currentBranchName ); let baseBranch = task.baseBranch; @@ -47,6 +47,4 @@ export async function pullRequest() { // create pull request await git.pullRequest(baseBranch, task.title); - - await git.pullRequest(baseBranch, title); }