Filter out empty items in bootstrap::flags::split

This commit is contained in:
Tyler Mandry
2020-09-29 22:50:57 +00:00
parent 63eaa60294
commit bf7aeaa617
+1 -1
View File
@@ -679,7 +679,7 @@ pub fn open(&self) -> bool {
}
fn split(s: &[String]) -> Vec<String> {
s.iter().flat_map(|s| s.split(',')).map(|s| s.to_string()).collect()
s.iter().flat_map(|s| s.split(',')).filter(|s| !s.is_empty()).map(|s| s.to_string()).collect()
}
fn parse_deny_warnings(matches: &getopts::Matches) -> Option<bool> {