this repo has no description

refactor: make version list display less cursed

+6 -7
+6 -7
src/versioning.rs
··· 63 63 64 64 impl Display for VersionList { 65 65 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { 66 - let mut out = String::new(); 67 - for version in &self.0 { 68 - out.push_str(&version.to_string()); 69 - out.push_str(", "); 70 - } 71 - out.pop(); // remove last comma 72 - out.pop(); // remove last space 66 + let out = self 67 + .0 68 + .iter() 69 + .map(ToString::to_string) 70 + .collect::<Vec<_>>() 71 + .join(", "); 73 72 write!(f, "{out}") 74 73 } 75 74 }