From b03f17265a90e238f6c5fa6ab010357d56615381 Mon Sep 17 00:00:00 2001 From: Eyal Delarea Date: Mon, 10 Apr 2023 17:26:46 +0300 Subject: [PATCH] Fix commit to master bug (#295) --- commands/createfixpullrequests.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/commands/createfixpullrequests.go b/commands/createfixpullrequests.go index c8ed1ffa5..64510c63e 100644 --- a/commands/createfixpullrequests.go +++ b/commands/createfixpullrequests.go @@ -206,8 +206,7 @@ func (cfp *CreateFixPullRequestsCmd) createFixingBranch(impactedPackage string, } log.Info("Creating branch:", fixBranchName) if exists { - log.Info("Branch:", fixBranchName, "already exists on remote.") - return + return "", fmt.Errorf("branch:%s already exists on remote", fixBranchName) } return fixBranchName, cfp.gitManager.CreateBranchAndCheckout(fixBranchName)