summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorToby Vincent <tobyv13@gmail.com>2022-11-12 12:33:17 -0600
committerToby Vincent <tobyv13@gmail.com>2022-11-12 12:33:17 -0600
commit2384c24f523edad42c97d96c6bb00c1013353144 (patch)
treeb8c903ca8d7f515c583294ec748f4b2e9a649f2a /src
parent6b9b3c885c1238dcbe512890badc4c5f93c8222f (diff)
refactor: change error to use Display instead of Debug
Diffstat (limited to 'src')
-rw-r--r--src/error.rs8
-rw-r--r--src/finder/error.rs2
-rw-r--r--src/paths/error.rs5
3 files changed, 6 insertions, 9 deletions
diff --git a/src/error.rs b/src/error.rs
index efd7193..9e20809 100644
--- a/src/error.rs
+++ b/src/error.rs
@@ -2,15 +2,15 @@ pub type Result<T> = std::result::Result<T, Error>;
#[derive(thiserror::Error, Debug)]
pub enum Error {
- #[error("IO error: {0:?}")]
+ #[error("IO error: {0}")]
IO(#[from] std::io::Error),
- #[error("Config error: {0:?}")]
+ #[error("Config error: {0}")]
Config(#[from] figment::error::Error),
- #[error("Directories error: {0:?}")]
+ #[error("Directories error: {0}")]
Directories(#[from] crate::paths::Error),
- #[error("Finder error: {0:?}")]
+ #[error("Finder error: {0}")]
Finder(#[from] crate::finder::Error),
}
diff --git a/src/finder/error.rs b/src/finder/error.rs
index 181da21..6ea5017 100644
--- a/src/finder/error.rs
+++ b/src/finder/error.rs
@@ -2,7 +2,7 @@ pub type Result<T> = std::result::Result<T, Error>;
#[derive(thiserror::Error, Debug)]
pub enum Error {
- #[error("IO error: {0:?}")]
+ #[error("IO error: {0}")]
IO(#[from] std::io::Error),
#[error("Stdin error: Failed to get finder's stdin")]
diff --git a/src/paths/error.rs b/src/paths/error.rs
index 13a69ea..08fdc89 100644
--- a/src/paths/error.rs
+++ b/src/paths/error.rs
@@ -1,8 +1,5 @@
#[derive(thiserror::Error, Debug)]
pub enum Error {
- #[error("Ignore error: {0:?}")]
+ #[error("Ignore error: {0}")]
Ignore(#[from] ignore::Error),
-
- #[error("Path contains invalid unicode: {0:?}")]
- Unicode(String),
}