Skip to content

Commit

Permalink
Use format_external in format_terms
Browse files Browse the repository at this point in the history
  • Loading branch information
zanieb committed Nov 30, 2023
1 parent 2f20e6c commit 2049810
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/report.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,10 +241,10 @@ impl<P: Package, VS: VersionSet> ReportFormatter<P, VS> for DefaultStringReportF
[(package, Term::Positive(range))] => format!("{} {} is forbidden", package, range),
[(package, Term::Negative(range))] => format!("{} {} is mandatory", package, range),
[(p1, Term::Positive(r1)), (p2, Term::Negative(r2))] => {
External::FromDependencyOf(p1, r1.clone(), p2, r2.clone()).to_string()
self.format_external(&External::FromDependencyOf(p1, r1.clone(), p2, r2.clone()))
}
[(p1, Term::Negative(r1)), (p2, Term::Positive(r2))] => {
External::FromDependencyOf(p2, r2.clone(), p1, r1.clone()).to_string()
self.format_external(&External::FromDependencyOf(p2, r2.clone(), p1, r1.clone()))
}
slice => {
let str_terms: Vec<_> = slice.iter().map(|(p, t)| format!("{} {}", p, t)).collect();
Expand Down

0 comments on commit 2049810

Please sign in to comment.