From 93d3bda837122bfc7a05ec20690bac2b49fbaf15 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Fri, 3 Jan 2020 18:47:53 +0100 Subject: Fix: Use module path when getting mail instead of using plain MessageId object in String representation Signed-off-by: Matthias Beyer --- lib/domain/libimagmail/src/store.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/domain/libimagmail/src/store.rs b/lib/domain/libimagmail/src/store.rs index 88f49df1..8b0200e1 100644 --- a/lib/domain/libimagmail/src/store.rs +++ b/lib/domain/libimagmail/src/store.rs @@ -27,7 +27,6 @@ use toml_query::insert::TomlValueInsertExt; use libimagstore::store::FileLockEntry; use libimagstore::store::Store; -use libimagstore::storeid::StoreId; use libimagstore::iter::Entries; use libimagentryref::hasher::default::DefaultHasher; use libimagentryref::reference::Config; @@ -137,7 +136,8 @@ impl<'a> MailStore<'a> for Store { fn get_mail(&'a self, mid: MessageId) -> Result>> { let mid_s : String = mid.into(); - self.get(StoreId::new(PathBuf::from(mid_s))?) + let sid = crate::module_path::new_id(PathBuf::from(mid_s))?; + self.get(sid) .and_then(|oe| match oe { Some(e) => if e.is_mail()? { Ok(Some(e)) -- cgit v1.2.3