[Auto] bin/core/edit: Fix Clippy warnings

Signed-off-by: flip1995 <hello@philkrones.com>
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
This commit is contained in:
flip1995 2019-08-27 10:39:39 +02:00 committed by Matthias Beyer
parent 98ccb41f7f
commit e010ef554d
2 changed files with 4 additions and 5 deletions

View file

@ -73,7 +73,7 @@ fn main() {
})
.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(|| {
@ -82,15 +82,15 @@ fn main() {
}))
.for_each(|mut entry| {
if edit_header {
let _ = entry
entry
.edit_header_and_content(&rt)
.map_err_trace_exit_unwrap();
} else if edit_header_only {
let _ = entry
entry
.edit_header(&rt)
.map_err_trace_exit_unwrap();
} else {
let _ = entry
entry
.edit_content(&rt)
.map_err_trace_exit_unwrap();
}

View file

@ -57,7 +57,6 @@ impl IdPathProvider for PathProvider {
fn get_ids(matches: &ArgMatches) -> Result<Option<Vec<StoreId>>> {
matches.values_of("entry")
.map(|v| v
.into_iter()
.map(PathBuf::from)
.map(|pb| pb.into_storeid())
.collect::<Result<Vec<_>>>()