From 13fa4c11b8e3744c7b19d98c9843abe3669f5c7c Mon Sep 17 00:00:00 2001 From: rascul Date: Sat, 16 Mar 2024 17:55:45 -0500 Subject: [PATCH] just print message for impl Display --- src/lib.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index a94cd6f..54d9afe 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -37,11 +37,7 @@ impl Rear { impl Display for Rear { fn fmt(&self, f: &mut Formatter<'_>) -> FmtResult { - if !self.message.is_empty() { - write!(f, "{}", self.error) - } else { - write!(f, "{}\n{}", &self.message, &self.error) - } + write!(f, "{}", &self.message) } }