diff options
author | flip1995 <hello@philkrones.com> | 2019-08-27 10:39:13 +0200 |
---|---|---|
committer | Matthias Beyer <mail@beyermatthias.de> | 2019-08-28 18:18:40 +0200 |
commit | 25e5936b08606d767d0316da8ea534b8b0bcde28 (patch) | |
tree | 79575371e8a198bf878fe1efeb11c957588a99d3 /bin | |
parent | 40c1f12b251f15c1ecb19a54b3227929a269bb9a (diff) |
[Auto] bin/core/category: Fix Clippy warnings
Signed-off-by: flip1995 <hello@philkrones.com>
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Diffstat (limited to 'bin')
-rw-r--r-- | bin/core/imag-category/src/main.rs | 10 | ||||
-rw-r--r-- | bin/core/imag-category/src/ui.rs | 1 |
2 files changed, 5 insertions, 6 deletions
diff --git a/bin/core/imag-category/src/main.rs b/bin/core/imag-category/src/main.rs index 633729d1..76bc593b 100644 --- a/bin/core/imag-category/src/main.rs +++ b/bin/core/imag-category/src/main.rs @@ -103,7 +103,7 @@ fn set(rt: &Runtime) { }) .into_iter(); - StoreIdIterator::new(Box::new(sids.into_iter().map(Ok))) + StoreIdIterator::new(Box::new(sids.map(Ok))) .into_get_iter(rt.store()) .trace_unwrap_exit() .map(|o| o.unwrap_or_else(|| { @@ -111,7 +111,7 @@ fn set(rt: &Runtime) { ::std::process::exit(1) })) .for_each(|mut entry| { - let _ = entry + entry .set_category_checked(rt.store(), &name) .map_err_trace_exit_unwrap(); }) @@ -129,7 +129,7 @@ fn get(rt: &Runtime) { }) .into_iter(); - StoreIdIterator::new(Box::new(sids.into_iter().map(Ok))) + StoreIdIterator::new(Box::new(sids.map(Ok))) .into_get_iter(rt.store()) .trace_unwrap_exit() .map(|o| o.unwrap_or_else(|| { @@ -138,7 +138,7 @@ fn get(rt: &Runtime) { })) .map(|entry| entry.get_category().map_err_trace_exit_unwrap()) .for_each(|name| { - let _ = writeln!(outlock, "{}", name).to_exit_code().unwrap_or_exit(); + writeln!(outlock, "{}", name).to_exit_code().unwrap_or_exit(); }) } @@ -190,7 +190,7 @@ fn delete_category(rt: &Runtime) { if answer { info!("Deleting category '{}'", name); - let _ = rt + rt .store() .delete_category(&name) .map_err_trace_exit_unwrap(); diff --git a/bin/core/imag-category/src/ui.rs b/bin/core/imag-category/src/ui.rs index f25aeca0..bea6bd82 100644 --- a/bin/core/imag-category/src/ui.rs +++ b/bin/core/imag-category/src/ui.rs @@ -111,7 +111,6 @@ impl IdPathProvider for PathProvider { fn get_id_paths(field: &str, subm: &ArgMatches) -> Result<Option<Vec<StoreId>>> { subm.values_of(field) .map(|v| v - .into_iter() .map(PathBuf::from) .map(|pb| pb.into_storeid()) .collect::<Result<Vec<_>>>() |