From 3b426f739bdac058e62b14d47bda1a40fe924227 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Tue, 26 Jul 2016 15:36:49 +0200 Subject: [PATCH] Replace Store::retrieve() with Store::get() --- imag-view/src/main.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/imag-view/src/main.rs b/imag-view/src/main.rs index 9f4040b1..6e96c10c 100644 --- a/imag-view/src/main.rs +++ b/imag-view/src/main.rs @@ -55,8 +55,12 @@ fn main() { Some(s) => s, }; - let entry = match rt.store().retrieve(PathBuf::from(entry_id)) { - Ok(fle) => fle, + let entry = match rt.store().get(PathBuf::from(entry_id)) { + Ok(Some(fle)) => fle, + Ok(None) => { + error!("Cannot get {}, there is no such id in the store", entry_id); + exit(1); + } Err(e) => { trace_error(&e); exit(1); // we can afford not-executing destructors here