Remove unnecessary Error::from() call

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
This commit is contained in:
Matthias Beyer 2019-03-09 12:24:09 +01:00
parent 341e64998d
commit d19020c3f5

View file

@ -68,7 +68,7 @@ impl<'a> Iterator for CategoryNameIter<'a> {
let func = |store: &Store| { // hack for returning Some(Result<_, _>) let func = |store: &Store| { // hack for returning Some(Result<_, _>)
store store
.get(sid)? .get(sid)?
.ok_or_else(|| Error::from(err_msg("Store read error")))? .ok_or_else(|| err_msg("Store read error"))?
.get_header() .get_header()
.read_string(query) .read_string(query)
.map_err(Error::from) .map_err(Error::from)