summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Beyer <matthias.beyer@atos.net>2019-04-30 14:28:52 +0200
committerMatthias Beyer <matthias.beyer@atos.net>2019-04-30 14:29:07 +0200
commit17a57a38aec2a8e8d9649b788be54ca0e85098cd (patch)
tree538a3390d613b8175c1fdf8c566305fdf409452e
parent01661264a04215af9a5370c26213e79c0fdd56a3 (diff)
downloadrepolocli-17a57a38aec2a8e8d9649b788be54ca0e85098cd.tar.gz
repolocli-17a57a38aec2a8e8d9649b788be54ca0e85098cd.tar.xz
Return error at end of function
-rw-r--r--src/main.rs9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs
index f225728..82236a8 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -165,7 +165,7 @@ fn app() -> Result<()> {
.into_iter()
.filter(|package| repository_filter.filter(package.repo()))
.collect();
- frontend.list_packages(packages)?;
+ frontend.list_packages(packages)
},
("problems", Some(mtch)) => {
trace!("Handling problems");
@@ -183,7 +183,7 @@ fn app() -> Result<()> {
.filter(|problem| repository_filter.filter(problem.repo()))
.collect();
- frontend.list_problems(problems)?;
+ frontend.list_problems(problems)
},
("compare", Some(mtch)) => {
let repos = mtch.values_of("compare-distros").unwrap().map(String::from).map(Repo::new).collect();
@@ -191,7 +191,7 @@ fn app() -> Result<()> {
let content = ::std::fs::read_to_string(file_path)?;
let pkgs : Vec<ComparePackage> = deserialize_package_list(content, file_path)?;
- frontend.compare_packages(pkgs, &backend, repos)?;
+ frontend.compare_packages(pkgs, &backend, repos)
},
(other, _mtch) => {
@@ -207,13 +207,12 @@ fn app() -> Result<()> {
.into_iter()
.filter(|package| repository_filter.filter(package.repo()))
.collect();
+
frontend.list_packages(packages)
})
.map_err(|_| format_err!("Unknown command: {}", other))
}
}
-
- Ok(())
}
fn print_error(e: Error) {