fix(push): check CurrentBranch

This commit is contained in:
江畅
2020-08-06 11:43:12 +08:00
parent deeda39c0e
commit 39e7da8a37
+4 -3
View File
@@ -345,9 +345,10 @@ Gerrit Code Review: http://code.google.com/p/gerrit/
if (not opt.new_branch and
project.GetUploadableBranch(project.CurrentBranch) is None):
continue
branch = project.GetBranch(project.CurrentBranch)
rb = ReviewableBranch(project, branch, branch.LocalMerge)
pending.append((project, [rb]))
if project.CurrentBranch:
branch = project.GetBranch(project.CurrentBranch)
rb = ReviewableBranch(project, branch, branch.LocalMerge)
pending.append((project, [rb]))
if opt.reviewers:
reviewers = _SplitUsers(opt.reviewers)