forked from mirrors/jj
cli: remove redundant deduplication of branch names from cmd_git_push()
This commit is contained in:
parent
237dd98b87
commit
b1267cae4b
1 changed files with 0 additions and 8 deletions
|
@ -670,12 +670,8 @@ fn cmd_git_push(
|
|||
let tx_description;
|
||||
let mut branch_updates = vec![];
|
||||
if args.all || args.deleted {
|
||||
let mut seen_branches = hashset! {};
|
||||
// TODO: Is it useful to warn about conflicted branches?
|
||||
for (branch_name, branch_target) in repo.view().branches() {
|
||||
if !seen_branches.insert(branch_name.clone()) {
|
||||
continue;
|
||||
}
|
||||
let push_action = classify_branch_push_action(branch_target, &remote);
|
||||
match push_action {
|
||||
BranchPushAction::AlreadyMatches
|
||||
|
@ -816,11 +812,7 @@ fn cmd_git_push(
|
|||
if branches.is_empty() {
|
||||
return Err(user_error("No current branch."));
|
||||
}
|
||||
let mut seen_branches = hashset! {};
|
||||
for (branch_name, branch_target) in branches {
|
||||
if !seen_branches.insert(branch_name.clone()) {
|
||||
continue;
|
||||
}
|
||||
let push_action = classify_branch_push_action(branch_target, &remote);
|
||||
match push_action {
|
||||
BranchPushAction::AlreadyMatches
|
||||
|
|
Loading…
Reference in a new issue