From 76e3d37009cc9ccd90251567356c5d844e8568ad Mon Sep 17 00:00:00 2001 From: "Aode (lion)" Date: Thu, 28 Oct 2021 21:07:31 -0500 Subject: [PATCH] Clean up ObjectStore's Debug impl --- src/store/object_store.rs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/store/object_store.rs b/src/store/object_store.rs index c8718cb..a47a2b6 100644 --- a/src/store/object_store.rs +++ b/src/store/object_store.rs @@ -39,7 +39,7 @@ pub(crate) enum ObjectError { Anyhow(#[from] anyhow::Error), } -#[derive(Debug, Clone)] +#[derive(Clone)] pub(crate) struct ObjectStore { path_gen: Generator, settings_tree: sled::Tree, @@ -230,3 +230,13 @@ where }) } } + +impl std::fmt::Debug for ObjectStore { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + f.debug_struct("ObjectStore") + .field("path_gen", &self.path_gen) + .field("bucket", &self.bucket.name) + .field("region", &self.bucket.region) + .finish() + } +}