Skip to content

Commit

Permalink
🧹
Browse files Browse the repository at this point in the history
  • Loading branch information
clabby committed Nov 4, 2024
1 parent f3adc2f commit 74c3173
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions src/subcommands/remote/submit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,14 +165,12 @@ impl SubmitCmd {
.await?;

// Update labels and assignees, if declared.
if metadata.labels.is_some() || metadata.assignees.is_some() {
if let Some(ref labels) = metadata.labels {
issues.add_labels(pr_info.number, labels).await?;
}
if let Some(ref assignees) = metadata.assignees {
let assignees = assignees.iter().map(AsRef::as_ref).collect::<Vec<_>>();
issues.add_assignees(pr_info.number, &assignees).await?;
}
if let Some(ref labels) = metadata.labels {
issues.add_labels(pr_info.number, labels).await?;
}
if let Some(ref assignees) = metadata.assignees {
let assignees = assignees.iter().map(AsRef::as_ref).collect::<Vec<_>>();
issues.add_assignees(pr_info.number, &assignees).await?;
}

// Update the tracked branch with the remote information.
Expand Down

0 comments on commit 74c3173

Please sign in to comment.