From 6b54e53586a059d6cea6fca315ae1613d365c61a Mon Sep 17 00:00:00 2001 From: Stephanie You Date: Tue, 5 Dec 2023 09:53:02 -0800 Subject: [PATCH] simplify single-branch logic --- go/libraries/doltcore/env/actions/clone.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go/libraries/doltcore/env/actions/clone.go b/go/libraries/doltcore/env/actions/clone.go index e0cac4b902..b1c3c6e183 100644 --- a/go/libraries/doltcore/env/actions/clone.go +++ b/go/libraries/doltcore/env/actions/clone.go @@ -215,7 +215,7 @@ func CloneRemote(ctx context.Context, srcDB *doltdb.DoltDB, remoteName, branch s // create remote refs corresponding to each of them. We delete all of // the local branches except for the one corresponding to |branch|. for _, br := range branches { - if !singleBranch || (singleBranch && br.GetPath() == branch) { + if !singleBranch || br.GetPath() == branch { cs, _ := doltdb.NewCommitSpec(br.GetPath()) cm, err := dEnv.DoltDB.Resolve(ctx, cs, nil) if err != nil {