From 580ea288776d2481fdbbeb383a226cc5ae34f4e5 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Tue, 5 Jul 2016 13:47:58 +0200 Subject: [PATCH] Fix Display impl for StoreId by using lossy string rep if PathBuf::to_str() fails --- libimagstore/src/storeid.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libimagstore/src/storeid.rs b/libimagstore/src/storeid.rs index d5b558ed..25e550ec 100644 --- a/libimagstore/src/storeid.rs +++ b/libimagstore/src/storeid.rs @@ -46,7 +46,7 @@ impl Display for StoreId { fn fmt(&self, fmt: &mut Formatter) -> RResult<(), FmtError> { match self.0.to_str() { Some(s) => write!(fmt, "{}", s), - None => write!(fmt, ""), // TODO: Sure here? + None => write!(fmt, "{}", self.0.to_string_lossy()), } }